Re: scsi_host_alloc does not check for used shost->host_no

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

 



Matthew Wilcox wrote:
> Or we could make the host_no a u64 and avoid the problem ever happening
> in our lifetimes.  I'm amazed that anyone's had the time to do 4 billion
> add/removes, to be honest.  Assuming it takes 1 second per add/remove
> cycle, and there's not even time to scan a bus in that time, that's
> still 136 years.

That was my thought as well, until I checked struct scsi_host and saw
that hostno is actually defined as a short there, which makes the problem
slightly easier to hit. So, we could just increase both of them to u64's
and be done with it...

-Brian

-- 
Brian King
Linux on Power Virtualization
IBM Linux Technology Center


--
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