Re: [RFC v3 06/19] arch: um: enable running kunit from User Mode Linux

2018-11-30 Thread Luis Chamberlain
On Fri, Nov 30, 2018 at 08:05:34AM -0600, Rob Herring wrote: > On Thu, Nov 29, 2018 at 9:37 PM Luis Chamberlain wrote: > > > > On Wed, Nov 28, 2018 at 03:26:03PM -0600, Rob Herring wrote: > > > On Wed, Nov 28, 2018 at 1:37 PM Brendan Higgins > > > wrote: &g

Re: [RFC v3 01/19] kunit: test: add KUnit test runner core

2018-11-29 Thread Luis Chamberlain
On Wed, Nov 28, 2018 at 11:36:18AM -0800, Brendan Higgins wrote: > +#define module_test(module) \ > + static int module_kunit_init##module(void) \ > + { \ > + return kunit_run_tests(); \ > + } \ > +

Re: [RFC v3 01/19] kunit: test: add KUnit test runner core

2018-11-29 Thread Luis Chamberlain
> +static void kunit_run_case_internal(struct kunit *test, > + struct kunit_module *module, > + struct kunit_case *test_case) > +{ > + int ret; > + > + if (module->init) { > + ret = module->init(test); > +

Re: [RFC v3 03/19] kunit: test: add string_stream a std::stream like string builder

2018-11-29 Thread Luis Chamberlain
On Wed, Nov 28, 2018 at 11:36:20AM -0800, Brendan Higgins wrote: > A number of test features need to do pretty complicated string printing > where it may not be possible to rely on a single preallocated string > with parameters. > > So provide a library for constructing the string as you go

Re: [RFC v3 06/19] arch: um: enable running kunit from User Mode Linux

2018-11-29 Thread Luis Chamberlain
On Wed, Nov 28, 2018 at 03:26:03PM -0600, Rob Herring wrote: > On Wed, Nov 28, 2018 at 1:37 PM Brendan Higgins > wrote: > > > > Make minimum number of changes outside of the KUnit directories for > > KUnit to build and run using UML. > > There's nothing in this patch limiting this to UML. Not

Re: [RFC v3 16/19] arch: um: make UML unflatten device tree when testing

2018-11-29 Thread Luis Chamberlain
On Wed, Nov 28, 2018 at 11:36:33AM -0800, Brendan Higgins wrote: > Make UML unflatten any present device trees when running KUnit tests. > > Signed-off-by: Brendan Higgins > --- > arch/um/kernel/um_arch.c | 4 > 1 file changed, 4 insertions(+) > > diff --git a/arch/um/kernel/um_arch.c

Re: [RFC v3 07/19] kunit: test: add initial tests

2018-11-29 Thread Luis Chamberlain
On Wed, Nov 28, 2018 at 11:36:24AM -0800, Brendan Higgins wrote: > Add a test for string stream along with a simpler example. > > Signed-off-by: Brendan Higgins > --- > kunit/Kconfig | 12 ++ > kunit/Makefile | 4 ++ > kunit/example-test.c | 88

Re: [RFC v3 08/19] arch: um: add shim to trap to allow installing a fault catcher for tests

2018-11-29 Thread Luis Chamberlain
On Wed, Nov 28, 2018 at 11:36:25AM -0800, Brendan Higgins wrote: > +static void segv_run_catcher(jmp_buf *catcher, void *fault_addr) > +{ > + current->thread.fault_addr = fault_addr; > + UML_LONGJMP(catcher, 1); > +} Some documentation about what this does exactly would be appreciated.

Re: [RFC v3 14/19] Documentation: kunit: add documentation for KUnit

2018-11-29 Thread Luis Chamberlain
On Thu, Nov 29, 2018 at 01:56:37PM +, Kieran Bingham wrote: > Hi Brendan, > > Please excuse the top posting, but I'm replying here as I'm following > the section "Creating a kunitconfig" in Documentation/kunit/start.rst. > > Could the three line kunitconfig file live under say >

Re: [RFC v3 11/19] kunit: add Python libraries for handing KUnit config and kernel

2018-11-29 Thread Luis Chamberlain
On Wed, Nov 28, 2018 at 11:36:28AM -0800, Brendan Higgins wrote: > The ultimate goal is to create minimal isolated test binaries; in the > meantime we are using UML to provide the infrastructure to run tests, so > define an abstract way to configure and run tests that allow us to > change the

Re: [RFC v2 00/14] kunit: introduce KUnit, the Linux kernel unit testing framework

2018-11-29 Thread Luis Chamberlain
On Wed, Nov 28, 2018 at 01:50:01PM -0700, shuah wrote: > On 11/28/18 12:54 PM, Knut Omang wrote: > > On Mon, 2018-11-26 at 17:41 -0800, Brendan Higgins wrote: > > Both approaches provide assertion macros for running tests inside the > > kernel, > > I doubt the kernel community would like to see

Re: [RFC v3 06/19] arch: um: enable running kunit from User Mode Linux

2018-11-29 Thread Luis Chamberlain
On Wed, Nov 28, 2018 at 11:36:23AM -0800, Brendan Higgins wrote: > Make minimum number of changes outside of the KUnit directories for > KUnit to build and run using UML. > > Signed-off-by: Brendan Higgins > --- > Kconfig | 2 ++ > Makefile | 2 +- > 2 files changed, 3 insertions(+), 1

Re: [RFC v3 08/19] arch: um: add shim to trap to allow installing a fault catcher for tests

2018-11-29 Thread Luis Chamberlain
On Wed, Nov 28, 2018 at 11:36:25AM -0800, Brendan Higgins wrote: > diff --git a/arch/um/kernel/trap.c b/arch/um/kernel/trap.c > index cced829460427..bf90e678b3d71 100644 > --- a/arch/um/kernel/trap.c > +++ b/arch/um/kernel/trap.c > @@ -201,6 +201,12 @@ void segv_handler(int sig, struct siginfo

Re: [RFC v3 01/19] kunit: test: add KUnit test runner core

2018-11-30 Thread Luis Chamberlain
On Fri, Nov 30, 2018 at 05:51:11PM -0800, Brendan Higgins wrote: > On Thu, Nov 29, 2018 at 7:14 PM Luis Chamberlain wrote: > > > > On Wed, Nov 28, 2018 at 11:36:18AM -0800, Brendan Higgins wrote: > > > +#define module_test(module) \ > > > + static i

Re: [RFC v3 01/19] kunit: test: add KUnit test runner core

2018-11-30 Thread Luis Chamberlain
On Wed, Nov 28, 2018 at 11:36:18AM -0800, Brendan Higgins wrote: > +int kunit_run_tests(struct kunit_module *module) > +{ > + bool all_passed = true, success; > + struct kunit_case *test_case; > + struct kunit test; > + int ret; > + > + ret = kunit_init_test(, module->name); >

Re: [RFC v3 01/19] kunit: test: add KUnit test runner core

2018-11-30 Thread Luis Chamberlain
On Fri, Nov 30, 2018 at 06:08:36PM -0800, Brendan Higgins wrote: > On Thu, Nov 29, 2018 at 7:28 PM Luis Chamberlain wrote: > > > > > +static void kunit_run_case_internal(struct kunit *test, > > > +

Re: [RFC v3 03/19] kunit: test: add string_stream a std::stream like string builder

2018-11-30 Thread Luis Chamberlain
On Fri, Nov 30, 2018 at 06:14:17PM -0800, Brendan Higgins wrote: > On Thu, Nov 29, 2018 at 7:29 PM Luis Chamberlain wrote: > > > > On Wed, Nov 28, 2018 at 11:36:20AM -0800, Brendan Higgins wrote: > > > A number of test features need to do pretty complicated string pri

Re: [RFC v3 11/19] kunit: add Python libraries for handing KUnit config and kernel

2018-12-04 Thread Luis Chamberlain
On Mon, Dec 03, 2018 at 03:50:48PM -0800, Brendan Higgins wrote: > On Thu, Nov 29, 2018 at 7:44 PM Luis Chamberlain wrote: > > > > On Wed, Nov 28, 2018 at 11:36:28AM -0800, Brendan Higgins wrote: > > > The ultimate goal is to create minimal isolated test binaries;

Re: [RFC v3 11/19] kunit: add Python libraries for handing KUnit config and kernel

2018-12-06 Thread Luis Chamberlain
On Thu, Dec 06, 2018 at 12:32:47PM +, Kieran Bingham wrote: > My main initial idea for a libumlinux is to provide infrastructure such > as our linked-lists and other kernel formatting so that we can take > kernel code directly to userspace for test and debug (assuming that > there are no

Re: [RFC v3 11/19] kunit: add Python libraries for handing KUnit config and kernel

2018-12-04 Thread Luis Chamberlain
On Mon, Dec 03, 2018 at 03:48:15PM -0800, Brendan Higgins wrote: > On Thu, Nov 29, 2018 at 5:54 AM Kieran Bingham > wrote: > > > > Hi Brendan, > > > > Thanks again for this series! > > > > On 28/11/2018 19:36, Brendan Higgins wrote: > > > The ultimate goal is to create minimal isolated test

Re: [RFC v3 07/19] kunit: test: add initial tests

2018-12-03 Thread Luis Chamberlain
On Mon, Dec 03, 2018 at 03:26:26PM -0800, Brendan Higgins wrote: > On Thu, Nov 29, 2018 at 7:40 PM Luis Chamberlain wrote: > > > > On Wed, Nov 28, 2018 at 11:36:24AM -0800, Brendan Higgins wrote: > > > Add a test for string stream along with a simpler example. > >

Re: [RFC v3 08/19] arch: um: add shim to trap to allow installing a fault catcher for tests

2018-12-03 Thread Luis Chamberlain
On Mon, Dec 03, 2018 at 03:34:57PM -0800, Brendan Higgins wrote: > On Thu, Nov 29, 2018 at 7:34 PM Luis Chamberlain wrote: > > > > On Wed, Nov 28, 2018 at 11:36:25AM -0800, Brendan Higgins wrote: > > > diff --git a/arch/um/kernel/trap.c b/arch/um/kernel/trap.c &

Re: [PATCH v5 01/18] kunit: test: add KUnit test runner core

2019-06-25 Thread Luis Chamberlain
On Tue, Jun 25, 2019 at 01:28:25PM -0700, Brendan Higgins wrote: > On Wed, Jun 19, 2019 at 5:15 PM Stephen Boyd wrote: > > > > Quoting Brendan Higgins (2019-06-17 01:25:56) > > > diff --git a/kunit/test.c b/kunit/test.c > > > new file mode 100644 > > > index 0..d05d254f1521f > > > ---

Re: [PATCH v5 06/18] kbuild: enable building KUnit

2019-06-25 Thread Luis Chamberlain
On Mon, Jun 17, 2019 at 01:26:01AM -0700, Brendan Higgins wrote: > diff --git a/Kconfig b/Kconfig > index 48a80beab6853..10428501edb78 100644 > --- a/Kconfig > +++ b/Kconfig > @@ -30,3 +30,5 @@ source "crypto/Kconfig" > source "lib/Kconfig" > > source "lib/Kconfig.debug" > + > +source

Re: [PATCH v5 01/18] kunit: test: add KUnit test runner core

2019-06-25 Thread Luis Chamberlain
On Mon, Jun 17, 2019 at 01:25:56AM -0700, Brendan Higgins wrote: > +/** > + * module_test() - used to register a kunit_module with KUnit. > + * @module: a statically allocated kunit_module. > + * > + * Registers @module with the test framework. See kunit_module for > more > + * information. >

Re: [PATCH v5 01/18] kunit: test: add KUnit test runner core

2019-06-25 Thread Luis Chamberlain
On Tue, Jun 25, 2019 at 03:14:45PM -0700, Brendan Higgins wrote: > On Tue, Jun 25, 2019 at 2:44 PM Luis Chamberlain wrote: > > Since its a new architecture and since you seem to imply most tests > > don't require locking or even IRQs disabled, I think its worth to > >

Re: [PATCH v5 06/18] kbuild: enable building KUnit

2019-06-25 Thread Luis Chamberlain
On Tue, Jun 25, 2019 at 03:41:29PM -0700, Brendan Higgins wrote: > On Tue, Jun 25, 2019 at 3:13 PM Luis Chamberlain wrote: > > > > On Mon, Jun 17, 2019 at 01:26:01AM -0700, Brendan Higgins wrote: > > > diff --git a/Kconfig b/Kconfig > > > index 48

Re: [PATCH v5 07/18] kunit: test: add initial tests

2019-06-25 Thread Luis Chamberlain
On Mon, Jun 17, 2019 at 01:26:02AM -0700, Brendan Higgins wrote: > diff --git a/kunit/example-test.c b/kunit/example-test.c > new file mode 100644 > index 0..f44b8ece488bb > --- /dev/null > +++ b/kunit/example-test.c <-- snip --> > +/* > + * This defines a suite or grouping of tests.

Re: [PATCH v6 01/18] kunit: test: add KUnit test runner core

2019-07-05 Thread Luis Chamberlain
oah-Hartman > Reviewed-by: Logan Gunthorpe Reviewed-by: Luis Chamberlain But a nitpick below, I think that can be fixed later with a follow up patch. > +/** > + * struct kunit - represents a running instance of a test. > + * @priv: for user to store arbitrary data. Commonly u

Re: [PATCH v6 01/18] kunit: test: add KUnit test runner core

2019-07-05 Thread Luis Chamberlain
On Wed, Jul 03, 2019 at 05:35:58PM -0700, Brendan Higgins wrote: > +struct kunit { > + void *priv; > + > + /* private: internal use only. */ > + const char *name; /* Read only after initialization! */ > + bool success; /* Read only after test_case finishes! */ > +}; No lock

Re: [PATCH v6 18/18] MAINTAINERS: add proc sysctl KUnit test to PROC SYSCTL section

2019-07-05 Thread Luis Chamberlain
On Wed, Jul 03, 2019 at 05:36:15PM -0700, Brendan Higgins wrote: > Add entry for the new proc sysctl KUnit test to the PROC SYSCTL section. > > Signed-off-by: Brendan Higgins > Reviewed-by: Greg Kroah-Hartman > Reviewed-by: Logan Gunthorpe > Acked-by: Luis Chamberla

Re: [PATCH v6 17/18] kernel/sysctl-test: Add null pointer test for sysctl.c:proc_dointvec()

2019-07-05 Thread Luis Chamberlain
urii Zaikin > Signed-off-by: Brendan Higgins > Reviewed-by: Greg Kroah-Hartman > Reviewed-by: Logan Gunthorpe Acked-by: Luis Chamberlain Luis

Re: [PATCH v6 02/18] kunit: test: add test resource management API

2019-07-05 Thread Luis Chamberlain
On Wed, Jul 03, 2019 at 05:35:59PM -0700, Brendan Higgins wrote: > diff --git a/kunit/test.c b/kunit/test.c > index c030ba5a43e40..a70fbe449e922 100644 > --- a/kunit/test.c > +++ b/kunit/test.c > @@ -122,7 +122,8 @@ static void kunit_print_test_case_ok_not_ok(struct > kunit_case *test_case, > >

Re: [PATCH v5 07/18] kunit: test: add initial tests

2019-07-02 Thread Luis Chamberlain
On Tue, Jul 02, 2019 at 10:52:50AM -0700, Brendan Higgins wrote: > On Wed, Jun 26, 2019 at 12:53 AM Brendan Higgins > wrote: > > > > On Tue, Jun 25, 2019 at 4:22 PM Luis Chamberlain wrote: > > > > > > On Mon, Jun 17, 2019 at 01:26:02AM -0700, Brendan Higgi

Re: [PATCH v5 13/18] kunit: tool: add Python wrappers for running KUnit tests

2019-06-26 Thread Luis Chamberlain
On Wed, Jun 26, 2019 at 01:02:55AM -0700, Brendan Higgins wrote: > On Tue, Jun 25, 2019 at 5:01 PM Luis Chamberlain wrote: > > > > On Mon, Jun 17, 2019 at 01:26:08AM -0700, Brendan Higgins wrote: > > > create mode 100644 > > > tools/testing/kunit/test_data/t

Re: [PATCH v5 01/18] kunit: test: add KUnit test runner core

2019-06-26 Thread Luis Chamberlain
On Tue, Jun 25, 2019 at 11:41:47PM -0700, Brendan Higgins wrote: > On Tue, Jun 25, 2019 at 4:02 PM Luis Chamberlain wrote: > > > > On Tue, Jun 25, 2019 at 03:14:45PM -0700, Brendan Higgins wrote: > > > On Tue, Jun 25, 2019 at 2:44 PM Luis Chamberlain > > &g

Re: [PATCH v5 18/18] MAINTAINERS: add proc sysctl KUnit test to PROC SYSCTL section

2019-06-25 Thread Luis Chamberlain
On Mon, Jun 17, 2019 at 01:26:13AM -0700, Brendan Higgins wrote: > Add entry for the new proc sysctl KUnit test to the PROC SYSCTL section. > > Signed-off-by: Brendan Higgins > Reviewed-by: Greg Kroah-Hartman > Reviewed-by: Logan Gunthorpe Acked-by: Luis Chamb

Re: [PATCH v5 00/18] kunit: introduce KUnit, the Linux kernel unit testing framework

2019-06-25 Thread Luis Chamberlain
On Wed, Jun 19, 2019 at 06:17:51PM -0700, Frank Rowand wrote: > It does not matter whether KUnit provides additional things, relative > to kselftest. The point I was making is that there appears to be > _some_ overlap between kselftest and KUnit, and if there is overlap > then it is worth

Re: [PATCH v5 01/18] kunit: test: add KUnit test runner core

2019-06-25 Thread Luis Chamberlain
On Tue, Jun 25, 2019 at 05:07:32PM -0700, Brendan Higgins wrote: > On Tue, Jun 25, 2019 at 3:33 PM Luis Chamberlain wrote: > > > > On Mon, Jun 17, 2019 at 01:25:56AM -0700, Brendan Higgins wrote: > > > +/** > > > + * module_test() - used to register a kunit_mod

Re: [PATCH v5 17/18] kernel/sysctl-test: Add null pointer test for sysctl.c:proc_dointvec()

2019-06-25 Thread Luis Chamberlain
On Mon, Jun 17, 2019 at 01:26:12AM -0700, Brendan Higgins wrote: > From: Iurii Zaikin > > KUnit tests for initialized data behavior of proc_dointvec that is > explicitly checked in the code. Includes basic parsing tests including > int min/max overflow. First, thanks for this work! My review

Re: [PATCH v5 13/18] kunit: tool: add Python wrappers for running KUnit tests

2019-06-25 Thread Luis Chamberlain
On Mon, Jun 17, 2019 at 01:26:08AM -0700, Brendan Higgins wrote: > create mode 100644 > tools/testing/kunit/test_data/test_is_test_passed-all_passed.log > create mode 100644 > tools/testing/kunit/test_data/test_is_test_passed-crash.log > create mode 100644 >

Re: [PATCH v5 17/18] kernel/sysctl-test: Add null pointer test for sysctl.c:proc_dointvec()

2019-06-28 Thread Luis Chamberlain
On Fri, Jun 28, 2019 at 01:01:54AM -0700, Brendan Higgins wrote: > On Wed, Jun 26, 2019 at 11:10 PM Luis Chamberlain wrote: > > > > On Wed, Jun 26, 2019 at 09:07:43PM -0700, Iurii Zaikin wrote: > > > On Tue, Jun 25, 2019 at 7:17 PM Luis Chamberlain > > &

Re: [PATCH v5 17/18] kernel/sysctl-test: Add null pointer test for sysctl.c:proc_dointvec()

2019-06-27 Thread Luis Chamberlain
On Wed, Jun 26, 2019 at 09:07:43PM -0700, Iurii Zaikin wrote: > On Tue, Jun 25, 2019 at 7:17 PM Luis Chamberlain wrote: > > > +static void sysctl_test_dointvec_table_maxlen_unset(struct kunit *test) > > > +{ > > > + struct ctl_table table = { > &

Re: [PATCH] video: fbdev: atyfb: only use ioremap_uc() on i386 and ia64

2019-11-13 Thread Luis Chamberlain
On Wed, Nov 13, 2019 at 11:31:54AM +0200, Andy Shevchenko wrote: > On Wed, Nov 13, 2019 at 08:38:15AM +0100, Arnd Bergmann wrote: > > On Wed, Nov 13, 2019 at 8:27 AM Christoph Hellwig wrote: > > > > > > On Tue, Nov 12, 2019 at 10:24:23PM +, Luis Chamberlain wrote:

Re: [PATCH] video: fbdev: atyfb: only use ioremap_uc() on i386 and ia64

2019-11-12 Thread Luis Chamberlain
On Tue, Nov 12, 2019 at 03:26:35PM +0100, Daniel Vetter wrote: > On Tue, Nov 12, 2019 at 3:06 PM Christoph Hellwig wrote: > > On Tue, Nov 12, 2019 at 02:04:16PM +0100, Daniel Vetter wrote: > > > Wut ... Maybe I'm missing something, but from how we use mtrr in other > > > gpu drivers it's a)

Re: [PATCH] video: fbdev: atyfb: only use ioremap_uc() on i386 and ia64

2019-11-12 Thread Luis Chamberlain
On Tue, Nov 12, 2019 at 03:06:31PM +0100, Christoph Hellwig wrote: > On Tue, Nov 12, 2019 at 02:04:16PM +0100, Daniel Vetter wrote: > > Wut ... Maybe I'm missing something, but from how we use mtrr in other > > gpu drivers it's a) either you use MTRR because that's all you got or > > b) you use

Re: [PATCH 0/8] Simplefs: group and simplify linux fs code

2020-04-16 Thread Luis Chamberlain
On Tue, Apr 14, 2020 at 02:42:54PM +0200, Emanuele Giuseppe Esposito wrote: > This series of patches introduce wrappers for functions, > arguments simplification in functions calls and most importantly > groups duplicated code in a single header, simplefs, to avoid redundancy > in the linux fs,

Re: [PATCH 1/8] apparmor: just use vfs_kern_mount to make .null

2020-04-16 Thread Luis Chamberlain
On Tue, Apr 14, 2020 at 02:42:55PM +0200, Emanuele Giuseppe Esposito wrote: > aa_mk_null_file is using simple_pin_fs/simple_release_fs with local > variables as arguments, for what would amount to a simple > vfs_kern_mount/mntput pair if everything was inlined. Just use > the normal filesystem

Re: [PATCH 2/8] fs: extract simple_pin/release_fs to separate files

2020-04-16 Thread Luis Chamberlain
On Tue, Apr 14, 2020 at 02:42:56PM +0200, Emanuele Giuseppe Esposito wrote: > We will augment this family of functions with inode management. To avoid > littering include/linux/fs.h and fs/libfs.c, move them to a separate header, > with a Kconfig symbol to enable them. If there are no functional

Re: [Intel-gfx] [PATCH 06/13] ocfs2: use new sysctl subdir helper register_sysctl_subdir()

2020-05-29 Thread Luis Chamberlain
On Fri, May 29, 2020 at 01:23:19AM -0700, Kees Cook wrote: > On Fri, May 29, 2020 at 07:41:01AM +0000, Luis Chamberlain wrote: > > This simplifies the code considerably. The following coccinelle > > SmPL grammar rule was used to transform this code. > > > > // pycocci s

Re: [PATCH 09/13] firmware_loader: simplify sysctl declaration with register_sysctl_subdir()

2020-05-29 Thread Luis Chamberlain
On Fri, May 29, 2020 at 12:26:13PM +0200, Greg KH wrote: > On Fri, May 29, 2020 at 07:41:04AM +0000, Luis Chamberlain wrote: > > From: Xiaoming Ni > > > > Move the firmware config sysctl table to fallback_table.c and use the > > new register_sysctl_subdir() helper. Th

Re: [PATCH 01/13] sysctl: add new register_sysctl_subdir() helper

2020-05-29 Thread Luis Chamberlain
On Fri, May 29, 2020 at 11:13:21AM +0300, Jani Nikula wrote: > On Fri, 29 May 2020, Luis Chamberlain wrote: > > Often enough all we need to do is create a subdirectory so that > > we can stuff sysctls underneath it. However, *if* that directory > > was already created early

[PATCH 00/13] sysctl: spring cleaning

2020-05-29 Thread Luis Chamberlain
seems reasonable we'll kdocify this a bit too. This code has been boot tested without issues, and I'm letting 0day do its thing to test against many kconfig builds. If you however spot any issues please let us know. Luis Chamberlain (9): sysctl: add new register_sysctl_subdir() helper cdrom

[PATCH 10/13] eventpoll: simplify sysctl declaration with register_sysctl_subdir()

2020-05-29 Thread Luis Chamberlain
From: Xiaoming Ni Move epoll_table sysctl to fs/eventpoll.c and remove the clutter out of kernel/sysctl.c by using register_sysctl_subdir().. Signed-off-by: Xiaoming Ni Signed-off-by: Luis Chamberlain --- fs/eventpoll.c | 10 +- include/linux/poll.h | 2 -- include/linux

[PATCH 03/13] hpet: use new sysctl subdir helper register_sysctl_subdir()

2020-05-29 Thread Luis Chamberlain
tifier c2.base; identifier c3.header; @@ header = -register_sysctl_table(base); +register_sysctl_subdir(E2, E1, sysctls); Generated-by: Coccinelle SmPL Signed-off-by: Luis Chamberlain --- drivers/char/hpet.c | 22 +- 1 file changed, 1 insertion(+), 21 deletions(-) diff --git a

[PATCH 06/13] ocfs2: use new sysctl subdir helper register_sysctl_subdir()

2020-05-29 Thread Luis Chamberlain
tifier c2.base; identifier c3.header; @@ header = -register_sysctl_table(base); +register_sysctl_subdir(E2, E1, sysctls); Generated-by: Coccinelle SmPL Signed-off-by: Luis Chamberlain --- fs/ocfs2/stackglue.c | 27 --- 1 file changed, 4 insertions(+), 23 deletions(-) diff --g

[PATCH 05/13] macintosh/mac_hid.c: use new sysctl subdir helper register_sysctl_subdir()

2020-05-29 Thread Luis Chamberlain
tifier c2.base; identifier c3.header; @@ header = -register_sysctl_table(base); +register_sysctl_subdir(E2, E1, sysctls); Generated-by: Coccinelle SmPL Signed-off-by: Luis Chamberlain --- drivers/macintosh/mac_hid.c | 25 ++--- 1 file changed, 2 insertions(+), 23 deletion

[PATCH 04/13] i915: use new sysctl subdir helper register_sysctl_subdir()

2020-05-29 Thread Luis Chamberlain
c2.E2; identifier c2.base; identifier c3.header; @@ header = -register_sysctl_table(base); +register_sysctl_subdir(E2, E1, sysctls); Generated-by: Coccinelle SmPL Signed-off-by: Luis Chamberlain --- drivers/gpu/drm/i915/i915_perf.c | 22 +- 1 file changed, 1 insertion(+), 21

[PATCH 08/13] inotify: simplify sysctl declaration with register_sysctl_subdir()

2020-05-29 Thread Luis Chamberlain
From: Xiaoming Ni move inotify_user sysctl to inotify_user.c and use the new register_sysctl_subdir() helper. Signed-off-by: Xiaoming Ni Signed-off-by: Luis Chamberlain --- fs/notify/inotify/inotify_user.c | 11 ++- include/linux/inotify.h | 3 --- kernel/sysctl.c

[PATCH 07/13] test_sysctl: use new sysctl subdir helper register_sysctl_subdir()

2020-05-29 Thread Luis Chamberlain
tifier c2.base; identifier c3.header; @@ header = -register_sysctl_table(base); +register_sysctl_subdir(E2, E1, sysctls); Generated-by: Coccinelle SmPL Signed-off-by: Luis Chamberlain --- lib/test_sysctl.c | 23 ++- 1 file changed, 2 insertions(+), 21 deletions(-) diff --git a/lib/test

[PATCH 01/13] sysctl: add new register_sysctl_subdir() helper

2020-05-29 Thread Luis Chamberlain
to place the new leaf files. So use a helper to do precisely this. Signed-off-by: Luis Chamberlain --- include/linux/sysctl.h | 11 +++ kernel/sysctl.c| 37 + 2 files changed, 48 insertions(+) diff --git a/include/linux/sysctl.h b/include/linux

[PATCH 13/13] fs: move binfmt_misc sysctl to its own file

2020-05-29 Thread Luis Chamberlain
This moves the binfmt_misc sysctl to its own file to help remove clutter from kernel/sysctl.c. Signed-off-by: Luis Chamberlain --- fs/binfmt_misc.c | 1 + kernel/sysctl.c | 7 --- 2 files changed, 1 insertion(+), 7 deletions(-) diff --git a/fs/binfmt_misc.c b/fs/binfmt_misc.c index

[PATCH 09/13] firmware_loader: simplify sysctl declaration with register_sysctl_subdir()

2020-05-29 Thread Luis Chamberlain
From: Xiaoming Ni Move the firmware config sysctl table to fallback_table.c and use the new register_sysctl_subdir() helper. This removes the clutter from kernel/sysctl.c. Signed-off-by: Xiaoming Ni Signed-off-by: Luis Chamberlain --- drivers/base/firmware_loader/fallback.c | 4

[PATCH 12/13] sysctl: add helper to register empty subdir

2020-05-29 Thread Luis Chamberlain
The way to create a subdirectory from the base set of directories is a bit obscure, so provide a helper which makes this clear, and also helps remove boiler plate code required to do this work. Signed-off-by: Luis Chamberlain --- include/linux/sysctl.h | 7 +++ kernel/sysctl.c| 16

[PATCH 02/13] cdrom: use new sysctl subdir helper register_sysctl_subdir()

2020-05-29 Thread Luis Chamberlain
tifier c2.base; identifier c3.header; @@ header = -register_sysctl_table(base); +register_sysctl_subdir(E2, E1, sysctls); Generated-by: Coccinelle SmPL Signed-off-by: Luis Chamberlain --- drivers/cdrom/cdrom.c | 23 ++- 1 file changed, 2 insertions(+), 21 deletions(-) diff --git

[PATCH 11/13] random: simplify sysctl declaration with register_sysctl_subdir()

2020-05-29 Thread Luis Chamberlain
From: Xiaoming Ni Move random_table sysctl from kernel/sysctl.c to drivers/char/random.c and use register_sysctl_subdir() to help remove the clutter out of kernel/sysctl.c. Signed-off-by: Xiaoming Ni Signed-off-by: Luis Chamberlain --- drivers/char/random.c | 14 -- include

Re: [PATCH v2 1/1] kernel.h: Split out panic and oops helpers

2021-04-10 Thread Luis Chamberlain
u > Acked-by: Rasmus Villemoes > Signed-off-by: Andrew Morton Acked-by: Luis Chamberlain Luis ___ dri-devel mailing list dri-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/dri-devel

Re: refactor the i915 GVT support

2021-08-20 Thread Luis Chamberlain
On Fri, Aug 20, 2021 at 04:17:24PM +0200, Christoph Hellwig wrote: > On Thu, Aug 19, 2021 at 04:29:29PM +0800, Zhenyu Wang wrote: > > I'm working on below patch to resolve this. But I met a weird issue in > > case when building i915 as module and also kvmgt module, it caused > > busy wait on

Re: refactor the i915 GVT support

2021-09-28 Thread Luis Chamberlain
;     a new struct with three entries that the main i915 module needs to >     request before enabling VGPU passthrough operations. > >     This also conveniently streamlines the GVT initialization and avoids >     the need for the global device pointer. > >     Signed-off-by:

[PATCH v2 3/8] macintosh/mac_hid.c: simplify subdirectory registration with register_sysctl()

2021-11-23 Thread Luis Chamberlain
r E3 = script:python(E2, E1) { make_my_fresh_expression(E2, E1) }; @@ header = -register_sysctl_table(base); +register_sysctl(E3, sysctls); Generated-by: Coccinelle SmPL Signed-off-by: Luis Chamberlain --- drivers/macintosh/mac_hid.c | 24 +--- 1 file changed, 1 insertion(+),

[PATCH v2 7/8] cdrom: simplify subdirectory registration with register_sysctl()

2021-11-23 Thread Luis Chamberlain
r E3 = script:python(E2, E1) { make_my_fresh_expression(E2, E1) }; @@ header = -register_sysctl_table(base); +register_sysctl(E3, sysctls); Generated-by: Coccinelle SmPL Signed-off-by: Luis Chamberlain --- drivers/cdrom/cdrom.c | 23 +-- 1 file changed, 1 insertion(+), 22

[PATCH v2 1/8] hpet: simplify subdirectory registration with register_sysctl()

2021-11-23 Thread Luis Chamberlain
fresh identifier E3 = script:python(E2, E1) { make_my_fresh_expression(E2, E1) }; @@ header = -register_sysctl_table(base); +register_sysctl(E3, sysctls); Generated-by: Coccinelle SmPL Signed-off-by: Luis Chamberlain --- drivers/char/hpet.c | 22 +- 1 file changed, 1 insertion(+),

[PATCH v2 6/8] inotify: simplify subdirectory registration with register_sysctl()

2021-11-23 Thread Luis Chamberlain
from kernel/sysctl.c. Signed-off-by: Xiaoming Ni [mcgrof: update commit log to reflect new path we decided to take] Signed-off-by: Luis Chamberlain --- fs/notify/inotify/inotify_user.c | 11 ++- include/linux/inotify.h | 3 --- kernel/sysctl.c | 21

[PATCH v2 0/8] sysctl: second set of kernel/sysctl cleanups

2021-11-23 Thread Luis Chamberlain
by Eric W. Biederman I dropped the subdir new call and just used the register_sysctl() by specifying the parent directory. * 0-day cleanups, commit log enhancements * Updated the coccinelle patch with register_sysctl() Luis Chamberlain (6): hpet: simplify subdirectory registration

[PATCH v2 4/8] ocfs2: simplify subdirectory registration with register_sysctl()

2021-11-23 Thread Luis Chamberlain
r E3 = script:python(E2, E1) { make_my_fresh_expression(E2, E1) }; @@ header = -register_sysctl_table(base); +register_sysctl(E3, sysctls); Generated-by: Coccinelle SmPL Signed-off-by: Luis Chamberlain --- fs/ocfs2/stackglue.c | 25 + 1 file changed, 1 insertion(+), 24 deletions(-

[PATCH v2 8/8] eventpoll: simplify sysctl declaration with register_sysctl()

2021-11-23 Thread Luis Chamberlain
sysctl knobs you wish to add for your own piece of code, we just care about the core logic. So move the epoll_table sysctl to fs/eventpoll.c and use use register_sysctl(). Signed-off-by: Xiaoming Ni Signed-off-by: Luis Chamberlain --- fs/eventpoll.c | 10 +- include/linux/poll.h

[PATCH v2 5/8] test_sysctl: simplify subdirectory registration with register_sysctl()

2021-11-23 Thread Luis Chamberlain
fresh identifier E3 = script:python(E2, E1) { make_my_fresh_expression(E2, E1) }; @@ header = -register_sysctl_table(base); +register_sysctl(E3, sysctls); Generated-by: Coccinelle SmPL Signed-off-by: Luis Chamberlain --- lib/test_sysctl.c | 22 +- 1 file changed, 1 insertion

[PATCH v2 2/8] i915: simplify subdirectory registration with register_sysctl()

2021-11-23 Thread Luis Chamberlain
r E3 = script:python(E2, E1) { make_my_fresh_expression(E2, E1) }; @@ header = -register_sysctl_table(base); +register_sysctl(E3, sysctls); Generated-by: Coccinelle SmPL Signed-off-by: Luis Chamberlain --- drivers/gpu/drm/i915/i915_perf.c | 22 +- 1 file changed, 1 insertion(+), 21

Re: [PATCH v2 6/8] inotify: simplify subdirectory registration with register_sysctl()

2021-11-24 Thread Luis Chamberlain
On Wed, Nov 24, 2021 at 10:44:09AM +0100, Jan Kara wrote: > On Tue 23-11-21 12:24:20, Luis Chamberlain wrote: > > From: Xiaoming Ni > > > > There is no need to user boiler plate code to specify a set of base > > directories we're going to stuff sysctls un

Re: [PATCH 12/13] sysctl: add helper to register empty subdir

2021-11-16 Thread Luis Chamberlain
On Fri, May 29, 2020 at 08:03:02AM -0500, Eric W. Biederman wrote: > Luis Chamberlain writes: > > > The way to create a subdirectory from the base set of directories > > is a bit obscure, so provide a helper which makes this clear, and > > also helps remove boiler p

Re: [PATCH v2 00/15] sysctl: Remove sentinel elements from drivers

2023-10-10 Thread Luis Chamberlain
On Mon, Oct 02, 2023 at 10:55:17AM +0200, Joel Granados via B4 Relay wrote: > Changes in v2: > - Left the dangling comma in the ctl_table arrays. > - Link to v1: > https://lore.kernel.org/r/20230928-jag-sysctl_remove_empty_elem_drivers-v1-0-e59120fca...@samsung.com Thanks! Pushed onto

Re: [PATCH v6 0/4] Let userspace know when snd-hda-intel needs i915

2022-05-09 Thread Luis Chamberlain
On Mon, May 09, 2022 at 06:23:35PM +0200, Mauro Carvalho Chehab wrote: > Currently, kernel/module annotates module dependencies when > request_symbol is used, but it doesn't cover more complex inter-driver > dependencies that are subsystem and/or driver-specific. > At this pount v5.18-rc7 is out

Re: [PATCH v6 0/4] Let userspace know when snd-hda-intel needs i915

2022-09-27 Thread Luis Chamberlain
On Tue, Sep 20, 2022 at 07:24:54AM +0200, Mauro Carvalho Chehab wrote: > Hi Luis, > > On Mon, 9 May 2022 13:38:28 -0700 > Luis Chamberlain wrote: > > > On Mon, May 09, 2022 at 06:23:35PM +0200, Mauro Carvalho Chehab wrote: > > > Currently, kernel/module anno

Re: enhancing module info to allow grouping of firmwares

2023-03-15 Thread Luis Chamberlain
On Thu, Mar 16, 2023 at 07:18:11AM +1000, Dave Airlie wrote: > MODULE_FIRMWARE_GROUP("g1") > MODULE_FIRMWARE("fwv1.bin") > MODULE_FIRMWARE("fwv2.bin") > MODULE_FIRMWARE_GROUP_END("g2") The way module namespaces were implemented could be used to leverage something like this, just that you'd use it

Re: [PATCH v4 1/4] video: fbdev: atyfb: only use ioremap_uc() on i386 and ia64

2023-03-08 Thread Luis Chamberlain
; the driver to call ioremap() means that they now have a chance > of working correctly. > > Signed-off-by: Arnd Bergmann > Signed-off-by: Baoquan He > Cc: Helge Deller > Cc: Thomas Zimmermann > Cc: Christophe Leroy > Cc: linux-fb...@vger.kernel.org > Cc: dri-devel@lists.f

Re: [PATCH 00/17] MODULE_LICENSE removals, sixth tranche

2023-03-03 Thread Luis Chamberlain
Stupid question, if you're removing MODULE_LICENSE() than why keep the other stupid MODULE_*() crap too? If its of no use, be gone! Luis

Re: [PATCH] modules/firmware: add a new option to denote a firmware group to choose one.

2023-04-24 Thread Luis Chamberlain
On Mon, Apr 24, 2023 at 10:01:13AM -0700, Lucas De Marchi wrote: > On Mon, Apr 24, 2023 at 03:44:18PM +1000, Dave Airlie wrote: > > On Fri, 21 Apr 2023 at 05:09, Lucas De Marchi > > wrote: > > > > > > On Wed, Apr 19, 2023 at 02:36:52PM +1000, Dave Airlie wrote: > > > >From: Dave Airlie > > > >

Re: [PATCH] modules/firmware: add a new option to denote a firmware group to choose one.

2023-05-02 Thread Luis Chamberlain
On Tue, May 02, 2023 at 11:11:58AM -0700, Lucas De Marchi wrote: > Based on the above and my previous reply, I think we should have > something more explicit about the order rather than relying on the > toolchain behavior. You can open code ELF sections and provide SORT() but you can also use

Re: [PATCH 2/2] modules/firmware: add a new option to denote a firmware group to choose one.

2023-07-07 Thread Luis Chamberlain
lback to installing all > the firmwares. > > The corresponding dracut code it at: > https://github.com/dracutdevs/dracut/pull/2309 > > Cc: Luis Chamberlain > Cc: linux-modu...@vger.kernel.org > Cc: dri-devel@lists.freedesktop.org > Signed-off-by: Dave Airlie Lucas, did this end up working for you as well? Luis

Re: [PATCH] modules/firmware: add a new option to denote a firmware group to choose one.

2023-05-23 Thread Luis Chamberlain
On Wed, May 24, 2023 at 03:35:41PM +1000, David Airlie wrote: > On Wed, May 24, 2023 at 3:26 PM Luis Chamberlain wrote: > > > > Hey Dave, just curious if there was going to be another follow up patch > > for this or if it was already posted. I don't see it clearly so just

Re: [PATCH] modules/firmware: add a new option to denote a firmware group to choose one.

2023-05-23 Thread Luis Chamberlain
On Wed, May 03, 2023 at 01:19:31PM +1000, Dave Airlie wrote: > > > > > > > >> > the GROUP until after the FIRMWARE, so this can't work, as it already > > >> > will have included all the ones below, hence why I bracketed top and > > >> > bottom with a group. > > >> > > >> well... that is something

Re: [PATCH 2/2] modules/firmware: add a new option to denote a firmware group to choose one.

2023-06-30 Thread Luis Chamberlain
On Thu, Jun 22, 2023 at 02:12:32PM -0700, Randy Dunlap wrote: > Is this going anywhere? It was posted about 2 months ago. Last I heard Dave was still working with Lucas on this? Luis

Re: [RFC v3 14/19] Documentation: kunit: add documentation for KUnit

2019-02-14 Thread Luis Chamberlain via dri-devel
On Wed, Feb 13, 2019 at 04:17:13PM -0800, Brendan Higgins wrote: > On Wed, Feb 13, 2019 at 1:55 PM Kieran Bingham > wrote: > Oh, yep, you are right. Does that mean we should bother at all with a > defconfig? If one wanted a qemu enabled type of kernel and also for kuniut one could imply run: