Fedora kernel-2.6.17-1.2142_FC4 patched with stable patch-2.6.17.4-vs2.0.2-rc26.diff
[linux-2.6.git] / drivers / scsi / psi240i.c
index aa505c1..5c2cdf5 100644 (file)
@@ -390,7 +390,7 @@ static irqreturn_t do_Irq_Handler (int irq, void *dev_id, struct pt_regs *regs)
  *     Returns:                Status code.
  *
  ****************************************************************/
-int Psi240i_QueueCommand (Scsi_Cmnd *SCpnt, void (*done)(Scsi_Cmnd *))
+static int Psi240i_QueueCommand (Scsi_Cmnd *SCpnt, void (*done)(Scsi_Cmnd *))
        {
        UCHAR              *cdb = (UCHAR *)SCpnt->cmnd;                                 // Pointer to SCSI CDB
        PADAPTER240I    padapter = HOSTDATA (SCpnt->device->host);                      // Pointer to adapter control structure
@@ -509,7 +509,7 @@ int Psi240i_QueueCommand (Scsi_Cmnd *SCpnt, void (*done)(Scsi_Cmnd *))
  *     Returns:                Nothing.
  *
  **************************************************************************/
-void ReadChipMemory (void *pdata, USHORT base, USHORT length, USHORT port)
+static void ReadChipMemory (void *pdata, USHORT base, USHORT length, USHORT port)
        {
        USHORT  z, zz;
        UCHAR   *pd = (UCHAR *)pdata;
@@ -538,7 +538,7 @@ void ReadChipMemory (void *pdata, USHORT base, USHORT length, USHORT port)
  *     Returns:                Number of adapters found.
  *
  ****************************************************************/
-int Psi240i_Detect (Scsi_Host_Template *tpnt)
+static int Psi240i_Detect (struct scsi_host_template *tpnt)
        {
        int                                     board;
        int                                     count = 0;
@@ -641,41 +641,6 @@ static int Psi240i_Release(struct Scsi_Host *shost)
        return 0;
 }
 
-/****************************************************************
- *     Name:   Psi240i_Abort
- *
- *     Description:    Process the Abort command from the SCSI manager.
- *
- *     Parameters:             SCpnt - Pointer to SCSI command structure.
- *
- *     Returns:                Allways snooze.
- *
- ****************************************************************/
-int Psi240i_Abort (Scsi_Cmnd *SCpnt)
-       {
-       DEB (printk ("psi240i_abort\n"));
-       return SCSI_ABORT_SNOOZE;
-       }
-/****************************************************************
- *     Name:   Psi240i_Reset
- *
- *     Description:    Process the Reset command from the SCSI manager.
- *
- *     Parameters:             SCpnt - Pointer to SCSI command structure.
- *                                     flags - Flags about the reset command
- *
- *     Returns:                No active command at this time, so this means
- *                                     that each time we got some kind of response the
- *                                     last time through.  Tell the mid-level code to
- *                                     request sense information in order to decide what
- *                                     to do next.
- *
- ****************************************************************/
-int Psi240i_Reset (Scsi_Cmnd *SCpnt, unsigned int reset_flags)
-       {
-       return SCSI_RESET_PUNT;
-       }
-
 /****************************************************************
  *     Name:   Psi240i_BiosParam
  *
@@ -689,12 +654,12 @@ int Psi240i_Reset (Scsi_Cmnd *SCpnt, unsigned int reset_flags)
  *     Returns:                zero.
  *
  ****************************************************************/
-int Psi240i_BiosParam (struct scsi_device *sdev, struct block_device *dev,
+static int Psi240i_BiosParam (struct scsi_device *sdev, struct block_device *dev,
                sector_t capacity, int geom[])
        {
        POUR_DEVICE     pdev;
 
-       pdev = &(HOSTDATA(sdev->host)->device[sdev->id]);
+       pdev = &(HOSTDATA(sdev->host)->device[sdev_id(sdev)]);
 
        geom[0] = pdev->heads;
        geom[1] = pdev->sectors;
@@ -704,14 +669,12 @@ int Psi240i_BiosParam (struct scsi_device *sdev, struct block_device *dev,
 
 MODULE_LICENSE("GPL");
 
-static Scsi_Host_Template driver_template = {
+static struct scsi_host_template driver_template = {
        .proc_name              = "psi240i", 
        .name                   = "PSI-240I EIDE Disk Controller",
        .detect                 = Psi240i_Detect,
        .release                = Psi240i_Release,
        .queuecommand           = Psi240i_QueueCommand,
-       .abort                  = Psi240i_Abort,
-       .reset                  = Psi240i_Reset,
        .bios_param             = Psi240i_BiosParam,
        .can_queue              = 1,
        .this_id                = -1,