lkml.org 
[lkml]   [2019]   [Jul]   [29]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectRe: [PATCH v2] driver core: Remove device link creation limitation
On Mon, Jul 29, 2019 at 10:47 PM Saravana Kannan <saravanak@google.com> wrote:
>
> Rafael,
>
> This is the fix you need. Or something link this.
>
> I had asked you to reject DL_FLAG_MANAGED as an input flag if you are
> marking it as internal (in the comments). But looks like you were also
> trying to check for "undefined" bit positions. However, the check
> isn't correct because DL_MANAGED_FLAGS doesn't include (rightfully so)
> DL_FLAG_PM_RUNTIME and DL_FLAG_RPM_ACTIVE .
>
> I tried to write a DL_FLAG_EXTERNAL to include all the external flags,
> but that felt like a maintenance headache that's not worth carrying. I
> think it's simpler to just error out when internal flags being passed
> in and ignore any undefined bit positions.

Well, IMO it is better to prevent people from passing unrecognized
flags to device_link_add() at all, even if that means some extra
effort when adding new flags.

I'll post an alternative fix shortly.

\
 
 \ /
  Last update: 2019-07-29 23:26    [W:0.089 / U:0.180 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site