Re: [PATCH] qla2xxx: Fix endianness of task management response code

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, 2012-09-19 at 07:09 -0700, Roland Dreier wrote:
> On Wed, Sep 19, 2012 at 12:59 AM, James Bottomley
> <James.Bottomley@xxxxxxxxxxxxxxxxxxxxx> wrote:
> > Is this also true on Big Endian Hardware?  Because the fix you have
> > assumes that the TIO IOCB with SCSI status mode 1 should be CPU
> > endian ... that doesn't look right since this is passed directly over
> > the PCI bus (and the PCI bus is little endian), so shouldn't the correct
> > fix be to replace cpu_to_be32 with cpu_to_le32?
> 
> After my patch the assignment is to a u8, and that byte is in the right
> place in memory.  So I don't think there's any endianness bug.

The data in status1 appears to get used a word at a time ... what about
the other three bytes you don't set; are they guaranteed to be zero? (in
which case this works, it just looks wrong from the way the thing is
used in the rest of the code).

James


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


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [SCSI Target Devel]     [Linux SCSI Target Infrastructure]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Samba]     [Device Mapper]
  Powered by Linux