lkml.org 
[lkml]   [2021]   [Jun]   [20]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [PATCH] drivers/nvme/host: Use kobj_to_dev() API
Date
Keith,

On 6/20/21 10:34, Keith Busch wrote:
> On Sat, Jun 19, 2021 at 01:01:34PM +0800, 周传高 wrote:
>>> On Fri, Jun 18, 2021 at 07:10:58AM -0700, zhouchuangao wrote:
>>>> Use kobj_to_dev() API instead of container_of().
>>> Why? That just makes the code harder to read.
>> In my opinion, the kobj_to_dev() interface is provided by the kernel so that
>> we can get device based on kobj without having to pass more parameters.
>> I think it's easier to use.
> This same patch has been proposed and rejected numerous times. Do we
> need to place a comment in the code to prevent future requests?
>
> http://lists.infradead.org/pipermail/linux-nvme/2021-March/023316.html
> http://lists.infradead.org/pipermail/linux-nvme/2021-February/023060.html
> http://lists.infradead.org/pipermail/linux-nvme/2020-September/019462.html
>
> _______________________________________________
> Linux-nvme mailing list
> Linux-nvme@lists.infradead.org
> http://lists.infradead.org/mailman/listinfo/linux-nvme
>

Just sent a patch with your suggested-by see if that is useful.


\
 
 \ /
  Last update: 2021-06-21 05:12    [W:0.065 / U:0.624 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site