Re: [PATCH] libata: Keep shadow last_ctl up to date during resets

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

 



Mark Lord wrote:
> Tejun Heo wrote:
>> Hello,
>>
>> Stuart MENEFY wrote:
>>> libata keeps a shadow copy of the ATA CTL register (which is write
>>> only),
>>> and only writes to the hardware when the required value doesn't match
>>> the shadow. However this copy wasn't being maintained when performing
>>> reset functions. This could cause problems for the first operation after
>>> a reset when the correct value might not be written to the CTL register.
>>>
>>> This problem was observed when hotplugging a drive: the identify command
>>> was being issued with interrupts enabled, when they should have been
>>> disabled.
>>>
>>> Signed-off-by: Stuart Menefy <stuart.menefy@xxxxxx>
>>
>> Nice catch.  Maybe a nice addition would be a ata_sff_write_to_ctl()
>> or something which always does the right thing.
>>
>> Acked-by: Tejun Heo <tj@xxxxxxxxxx>
> ..
> 
> Mmm.. I wonder if this is severe enough to warrant backporting
> to -stable for the past couple of releases?

Yeah, I think it can be responsible for at least some of runaway IRQs
during detection on ata_piix and is likely to be a good candidate for
-stable but I think it would be better to see how it does on -rc first
for a while before pushing this -stable.  sata_nv breakages very well
showed how messed up things can get with obvious fixes.  :-)

Thanks.

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

[Index of Archives]     [Linux Filesystems]     [Linux SCSI]     [Linux RAID]     [Git]     [Kernel Newbies]     [Linux Newbie]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Samba]     [Device Mapper]

  Powered by Linux