> +static void synchronize_callback(void *context, struct fib * fibptr)
> +{
> +     struct aac_synchronize_reply * synchronizereply;
> +     struct scsi_cmnd * scsicmd;

Superflous whitespaces before the *.  Also the canonical name for
scsi_cmnds seems to be cmd - that makes easiert to read code.

> +
> +     scsicmd = (struct scsi_cmnd *) context;

No need to cast.  You could also move the assigment into the declaration.

> +
> +     dprintk((KERN_DEBUG "synchronize_callback[cpu %d]: t = %ld.\n", 
> smp_processor_id(), jiffies));

please linewrrap after 80 chars

> +     if (fibptr == NULL)
> +             BUG();

BUG_ON()

> +     synchronizereply = (struct aac_synchronize_reply *) fib_data(fibptr);

fib_data return void *, no cast needed.

> 
> +     if (le32_to_cpu(synchronizereply->status) == CT_OK) {
> +             scsicmd->result = DID_OK << 16 | COMMAND_COMPLETE << 8 | 
> SAM_STAT_GOOD;

linelength again.

> 
> +     } else {
> +             struct scsi_device * device = scsicmd->device;

Canonical name is sdev, superflous space again.

> +             set_sense((u8 *) &dev->fsa_dev[cid].sense_data,

sense_data is u8 already.

> +             memcpy(scsicmd->sense_buffer, &dev->fsa_dev[cid].sense_data,
> +               (sizeof(dev->fsa_dev[cid].sense_data) > 
> sizeof(scsicmd->sense_buffer))
> +                 ? sizeof(scsicmd->sense_buffer)
> +                 : sizeof(dev->fsa_dev[cid].sense_data));

Use max here?

> +             if ((cmd != scsicmd) && (cmd->serial_number != 0)) {

superflous braces.

> +/* XXX */printk(KERN_DEBUG "aac_synchronize[cpu %d]: t = %ld.\n", 
> smp_processor_id(), jiffies);
> +/* XXX       dprintk((KERN_DEBUG "aac_synchronize[cpu %d]: t = %ld.\n", 
> smp_processor_id(), jiffies)); */

take this out?

-
To unsubscribe from this list: send the line "unsubscribe linux-scsi" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to