Re: [PATCH] Documentation: security/credentials.rst: explain need to sort group_list

2018-01-08 Thread Jonathan Corbet
On Mon, 08 Jan 2018 10:39:14 +1100 NeilBrown wrote: > > There is value in using the c:func syntax, as it will generate > > cross-references to the kerneldoc comments for those functions. In this > > case, it would appear that these comments exist, but nobody has pulled > > them into the docs yet

Re: [PATCH] Documentation: security/credentials.rst: explain need to sort group_list

2018-01-08 Thread Jonathan Corbet
On Sat, 6 Jan 2018 12:20:13 -0800 Matthew Wilcox wrote: > I've been thinking about all the kernel-doc we have that's completely > unincorporated. I've also been thinking about core-api/kernel-api.rst > which to my mind is completely unreadable in its current form -- look at > https://www.kernel.

Re: [PATCH] Documentation: security/credentials.rst: explain need to sort group_list

2018-01-07 Thread NeilBrown
On Sat, Jan 06 2018, Jonathan Corbet wrote: > There is value in using the c:func syntax, as it will generate > cross-references to the kerneldoc comments for those functions. In this > case, it would appear that these comments exist, but nobody has pulled > them into the docs yet. I took the lib

Re: [PATCH] Documentation: security/credentials.rst: explain need to sort group_list

2018-01-06 Thread Randy Dunlap
On 01/06/18 12:20, Matthew Wilcox wrote: > > I've been thinking about all the kernel-doc we have that's completely > unincorporated. I've also been thinking about core-api/kernel-api.rst > which to my mind is completely unreadable in its current form -- look at > https://www.kernel.org/doc/html/l

Re: [PATCH] Documentation: security/credentials.rst: explain need to sort group_list

2018-01-06 Thread Matthew Wilcox
On Sat, Jan 06, 2018 at 11:09:08AM -0700, Jonathan Corbet wrote: > On Tue, 2 Jan 2018 13:04:31 -0800 > Matthew Wilcox wrote: > > > > +When replacing the group list, the new list must be sorted before it > > > +is added to the credential, as a binary search is used to test for > > > +membership.

Re: [PATCH] Documentation: security/credentials.rst: explain need to sort group_list

2018-01-06 Thread Jonathan Corbet
On Tue, 2 Jan 2018 13:04:31 -0800 Matthew Wilcox wrote: > > +When replacing the group list, the new list must be sorted before it > > +is added to the credential, as a binary search is used to test for > > +membership. In practice, this means ``groups_sort()`` should be > > For a .rst file, s

Re: [PATCH] Documentation: security/credentials.rst: explain need to sort group_list

2018-01-02 Thread Matthew Wilcox
On Wed, Jan 03, 2018 at 08:01:15AM +1100, NeilBrown wrote: > > +When replacing the group list, the new list must be sorted before it > +is added to the credential, as a binary search is used to test for > +membership. In practice, this means ``groups_sort()`` should be For a .rst file, shouldn'

[PATCH] Documentation: security/credentials.rst: explain need to sort group_list

2018-01-02 Thread NeilBrown
This patch updates the documentation with the observations that led to commit bdcf0a423ea1 ("kernel: make groups_sort calling a responsibility group_info allocators") and the new behaviour required. Specifically that groups_sort() should be called on a new group_list before set_groups() or set_cur