Re: [PATCH v3 08/11] driver-core: Introduce DEVICE_ATTR_ADMIN_{RO,RW}

2020-07-21 Thread Greg Kroah-Hartman
On Mon, Jul 20, 2020 at 03:08:07PM -0700, Dan Williams wrote: > A common pattern for using plain DEVICE_ATTR() instead of > DEVICE_ATTR_RO() and DEVICE_ATTR_RW() is for attributes that want to > limit read to only root. I.e. many users of DEVICE_ATTR() are > specifying 0400 or 0600 for

[PATCH v3 08/11] driver-core: Introduce DEVICE_ATTR_ADMIN_{RO,RW}

2020-07-20 Thread Dan Williams
A common pattern for using plain DEVICE_ATTR() instead of DEVICE_ATTR_RO() and DEVICE_ATTR_RW() is for attributes that want to limit read to only root. I.e. many users of DEVICE_ATTR() are specifying 0400 or 0600 for permissions. Given the expectation that CAP_SYS_ADMIN is needed to access these