Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input
[firefly-linux-kernel-4.4.55.git] / drivers / scsi / dc395x.c
index ff2b1796fa34634ac95b3eee22051743dc706819..564ea90ed3a00a18cccb80b63799a236297dc579 100644 (file)
@@ -541,7 +541,7 @@ static struct ParameterData __devinitdata cfg_data[] = {
 
 
 /*
- * Safe settings. If set to zero the the BIOS/default values with
+ * Safe settings. If set to zero the BIOS/default values with
  * command line overrides will be used. If set to 1 then safe and
  * slow settings will be used.
  */
@@ -617,7 +617,7 @@ static void __devinit fix_settings(void)
 
 /*
  * Mapping from the eeprom delay index value (index into this array)
- * to the the number of actual seconds that the delay should be for.
+ * to the number of actual seconds that the delay should be for.
  */
 static char __devinitdata eeprom_index_to_delay_map[] = 
        { 1, 3, 5, 10, 16, 30, 60, 120 };
@@ -1219,7 +1219,7 @@ static void dump_register_info(struct AdapterCtlBlk *acb,
                                srb, srb->cmd, srb->cmd->pid,
                                srb->cmd->cmnd[0], srb->cmd->device->id,
                                srb->cmd->device->lun);
-               printk("  sglist=%p cnt=%i idx=%i len=%i\n",
+               printk("  sglist=%p cnt=%i idx=%i len=%zu\n",
                       srb->segment_x, srb->sg_count, srb->sg_index,
                       srb->total_xfer_length);
                printk("  state=0x%04x status=0x%02x phase=0x%02x (%sconn.)\n",
@@ -1813,10 +1813,9 @@ static void dc395x_handle_interrupt(struct AdapterCtlBlk *acb,
 }
 
 
-static irqreturn_t dc395x_interrupt(int irq, void *dev_id,
-               struct pt_regs *regs)
+static irqreturn_t dc395x_interrupt(int irq, void *dev_id)
 {
-       struct AdapterCtlBlk *acb = (struct AdapterCtlBlk *)dev_id;
+       struct AdapterCtlBlk *acb = dev_id;
        u16 scsi_status;
        u8 dma_status;
        irqreturn_t handled = IRQ_NONE;
@@ -4137,7 +4136,7 @@ static void __devinit trms1040_write_all(struct NvRamType *eeprom, unsigned long
  * @io_port:   base I/O address
  * @addr:      offset into SEEPROM
  *
- * Returns the the byte read.
+ * Returns the byte read.
  **/
 static u8 __devinit trms1040_get_data(unsigned long io_port, u8 addr)
 {
@@ -4320,7 +4319,7 @@ static int __devinit adapter_sg_tables_alloc(struct AdapterCtlBlk *acb)
 
        dprintkdbg(DBG_1, "Allocate %i pages for SG tables\n", pages);
        while (pages--) {
-               ptr = (struct SGentry *)kmalloc(PAGE_SIZE, GFP_KERNEL);
+               ptr = kmalloc(PAGE_SIZE, GFP_KERNEL);
                if (!ptr) {
                        adapter_sg_tables_free(acb);
                        return 1;
@@ -4949,7 +4948,7 @@ static struct pci_driver dc395x_driver = {
  **/
 static int __init dc395x_module_init(void)
 {
-       return pci_module_init(&dc395x_driver);
+       return pci_register_driver(&dc395x_driver);
 }