Re: [PATCH v3 7/9] driver core: Correct parameter check for API device_for_each_child_reverse_from()

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

 



On 2024/12/16 23:23, Jonathan Cameron wrote:
>> Correct the API's parameter @parent check by (!parent || !parent->p).
>>
>> Signed-off-by: Zijun Hu <quic_zijuhu@xxxxxxxxxxx>
> Given that 'from' implies continuation of an iteration I can see why
> it might not ever be relevant to check parent.  It's harmless, but to
> my mind unnecessary.

the extra check !parent has no overhead and make this check consistent
with others in the cluster. (^^)




[Index of Archives]     [Linux RAID]     [Linux SCSI]     [Linux ATA RAID]     [IDE]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Device Mapper]

  Powered by Linux