Re: [PATCH v2 2/2] auxdisplay: panel: avoid gcc 8's Wstringop-truncation warning

2018-08-01 Thread Miguel Ojeda
On Wed, Aug 1, 2018 at 8:47 PM, Kees Cook wrote: > On Wed, Aug 1, 2018 at 10:58 AM, Miguel Ojeda > wrote: >> Let gcc know it is not meant to be NUL-terminated by annotating with >> the new __nonstring variable attribute; and remove the comment since it >> conveys the sa

[PATCH v2 2/2] auxdisplay: panel: avoid gcc 8's Wstringop-truncation warning

2018-08-01 Thread Miguel Ojeda
Let gcc know it is not meant to be NUL-terminated by annotating with the new __nonstring variable attribute; and remove the comment since it conveys the same information. Cc: Willy Tarreau Cc: Geert Uytterhoeven Cc: Martin Sebor Signed-off-by: Miguel Ojeda --- drivers/auxdisplay/panel.c | 7

[PATCH v2 2/2] auxdisplay: panel: avoid gcc 8's Wstringop-truncation warning

2018-08-01 Thread Miguel Ojeda
Let gcc know it is not meant to be NUL-terminated by annotating with the new __nonstring variable attribute; and remove the comment since it conveys the same information. Cc: Willy Tarreau Cc: Geert Uytterhoeven Cc: Martin Sebor Signed-off-by: Miguel Ojeda --- drivers/auxdisplay/panel.c | 7

[PATCH v2 1/2] Support the nonstring variable attribute (gcc >= 8)

2018-08-01 Thread Miguel Ojeda
Cc: Will Deacon Cc: Greg Kroah-Hartman Cc: David Rientjes Cc: Martin Sebor Cc: Arnd Bergmann Signed-off-by: Miguel Ojeda --- Re-sending this since a few months have passed, Martin has improved GCC's feature and warnings are appearing in Geert's build bot. Added an example in the second patch as reques

[PATCH v2 1/2] Support the nonstring variable attribute (gcc >= 8)

2018-08-01 Thread Miguel Ojeda
Cc: Will Deacon Cc: Greg Kroah-Hartman Cc: David Rientjes Cc: Martin Sebor Cc: Arnd Bergmann Signed-off-by: Miguel Ojeda --- Re-sending this since a few months have passed, Martin has improved GCC's feature and warnings are appearing in Geert's build bot. Added an example in the second patch as reques

Re: [PATCH] MAINTAINERS: Add .clang-format entry

2018-08-01 Thread Miguel Ojeda
Hi Jason, On Tue, Jul 31, 2018 at 4:59 AM, Jason Gunthorpe wrote: > On Mon, Jul 30, 2018 at 06:24:31PM +0200, Miguel Ojeda wrote: >> As discussed in https://lkml.org/lkml/2018/6/25/877 >> >> Signed-off-by: Miguel Ojeda >> --- >> MAINTAINERS | 5 +

Re: [PATCH] MAINTAINERS: Add .clang-format entry

2018-08-01 Thread Miguel Ojeda
Hi Jason, On Tue, Jul 31, 2018 at 4:59 AM, Jason Gunthorpe wrote: > On Mon, Jul 30, 2018 at 06:24:31PM +0200, Miguel Ojeda wrote: >> As discussed in https://lkml.org/lkml/2018/6/25/877 >> >> Signed-off-by: Miguel Ojeda >> --- >> MAINTAINERS | 5 +

Re: Build regressions/improvements in v4.18-rc7

2018-08-01 Thread Miguel Ojeda
Hi Geert, On Wed, Aug 1, 2018 at 8:56 AM, Geert Uytterhoeven wrote: > Hi Miguel, > > On Mon, Jul 30, 2018 at 6:05 PM Miguel Ojeda > wrote: >> On Mon, Jul 30, 2018 at 8:46 AM, Geert Uytterhoeven >> wrote: >> > Below is the list of build error/warning regressions

Re: Build regressions/improvements in v4.18-rc7

2018-08-01 Thread Miguel Ojeda
Hi Geert, On Wed, Aug 1, 2018 at 8:56 AM, Geert Uytterhoeven wrote: > Hi Miguel, > > On Mon, Jul 30, 2018 at 6:05 PM Miguel Ojeda > wrote: >> On Mon, Jul 30, 2018 at 8:46 AM, Geert Uytterhoeven >> wrote: >> > Below is the list of build error/warning regressions

Re: Build regressions/improvements in v4.18-rc7

2018-08-01 Thread Miguel Ojeda
Hi Martin, On Tue, Jul 31, 2018 at 9:59 PM, Martin Sebor wrote: > > Thanks for pointing this out! > Thanks to *you* for doing all the work behind this! > The first two calls are diagnosed because GCC uses the size > of the destination array as the size of the accessed object > (it would be

Re: Build regressions/improvements in v4.18-rc7

2018-08-01 Thread Miguel Ojeda
Hi Martin, On Tue, Jul 31, 2018 at 9:59 PM, Martin Sebor wrote: > > Thanks for pointing this out! > Thanks to *you* for doing all the work behind this! > The first two calls are diagnosed because GCC uses the size > of the destination array as the size of the accessed object > (it would be

[PATCH] MAINTAINERS: Add .clang-format entry

2018-07-30 Thread Miguel Ojeda
As discussed in https://lkml.org/lkml/2018/6/25/877 Signed-off-by: Miguel Ojeda --- MAINTAINERS | 5 + 1 file changed, 5 insertions(+) diff --git a/MAINTAINERS b/MAINTAINERS index 0fe4228f78cb..2352788d6852 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -3514,6 +3514,11 @@ M: Dave

[PATCH] MAINTAINERS: Add .clang-format entry

2018-07-30 Thread Miguel Ojeda
As discussed in https://lkml.org/lkml/2018/6/25/877 Signed-off-by: Miguel Ojeda --- MAINTAINERS | 5 + 1 file changed, 5 insertions(+) diff --git a/MAINTAINERS b/MAINTAINERS index 0fe4228f78cb..2352788d6852 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -3514,6 +3514,11 @@ M: Dave

Re: Build regressions/improvements in v4.18-rc7

2018-07-30 Thread Miguel Ojeda
Hi Geert, Martin, all, On Mon, Jul 30, 2018 at 8:46 AM, Geert Uytterhoeven wrote: > Below is the list of build error/warning regressions/improvements in > v4.18-rc7[1] compared to v4.17[2]. There are quite some -Wstringop-* warnings, so here is some information that may be useful and/or save

Re: Build regressions/improvements in v4.18-rc7

2018-07-30 Thread Miguel Ojeda
Hi Geert, Martin, all, On Mon, Jul 30, 2018 at 8:46 AM, Geert Uytterhoeven wrote: > Below is the list of build error/warning regressions/improvements in > v4.18-rc7[1] compared to v4.17[2]. There are quite some -Wstringop-* warnings, so here is some information that may be useful and/or save

Re: [PATCH RESEND] clang-format: Set IndentWrappedFunctionNames false

2018-06-27 Thread Miguel Ojeda
On Tue, Jun 26, 2018 at 9:33 PM, Jason Gunthorpe wrote: > On Tue, Jun 26, 2018 at 05:05:40PM +0200, Miguel Ojeda wrote: >> Hi, >> >> On Tue, Jun 26, 2018 at 12:44 AM, Jason Gunthorpe wrote: >> > The true option causes this indenting for functions: >> > >

Re: [PATCH RESEND] clang-format: Set IndentWrappedFunctionNames false

2018-06-27 Thread Miguel Ojeda
On Tue, Jun 26, 2018 at 9:33 PM, Jason Gunthorpe wrote: > On Tue, Jun 26, 2018 at 05:05:40PM +0200, Miguel Ojeda wrote: >> Hi, >> >> On Tue, Jun 26, 2018 at 12:44 AM, Jason Gunthorpe wrote: >> > The true option causes this indenting for functions: >> > >

Re: [PATCH RESEND] clang-format: Set IndentWrappedFunctionNames false

2018-06-26 Thread Miguel Ojeda
iginally thought that it would be picked up by Andrew or some other "general" tree instead.) > > Would prefer Miguel's Ack to do that though. Looks like Andrew Morton > took the original patch introducing the file? Yep, I sent it to Andrew and he kindly picked it up. Probably he

Re: [PATCH RESEND] clang-format: Set IndentWrappedFunctionNames false

2018-06-26 Thread Miguel Ojeda
iginally thought that it would be picked up by Andrew or some other "general" tree instead.) > > Would prefer Miguel's Ack to do that though. Looks like Andrew Morton > took the original patch introducing the file? Yep, I sent it to Andrew and he kindly picked it up. Probably he

Re: [PATCH v4] MAINTAINERS: Add file patterns for auxdisplay device tree bindings

2018-06-22 Thread Miguel Ojeda
On Fri, Jun 22, 2018 at 12:07 PM, Geert Uytterhoeven wrote: > Submitters of device tree binding documentation may forget to CC > the subsystem maintainer if this is missing. > > Signed-off-by: Geert Uytterhoeven Acked-by: Miguel Ojeda Thanks, Miguel > --- > v3: > - Upd

Re: [PATCH v4] MAINTAINERS: Add file patterns for auxdisplay device tree bindings

2018-06-22 Thread Miguel Ojeda
On Fri, Jun 22, 2018 at 12:07 PM, Geert Uytterhoeven wrote: > Submitters of device tree binding documentation may forget to CC > the subsystem maintainer if this is missing. > > Signed-off-by: Geert Uytterhoeven Acked-by: Miguel Ojeda Thanks, Miguel > --- > v3: > - Upd

Re: [GIT PULL] auxdisplay for v4.18-rc1

2018-06-07 Thread Miguel Ojeda
Hi Linus, On Thu, Jun 7, 2018 at 4:22 PM, Miguel Ojeda wrote: > The following changes since commit 0adb32858b0bddf4ada5f364a84ed60b196dbcda: > > Linux 4.16 (2018-04-01 14:20:27 -0700) > > are available in the git repository at: > > https://github.com/ojeda/linux.git tags

Re: [GIT PULL] auxdisplay for v4.18-rc1

2018-06-07 Thread Miguel Ojeda
Hi Linus, On Thu, Jun 7, 2018 at 4:22 PM, Miguel Ojeda wrote: > The following changes since commit 0adb32858b0bddf4ada5f364a84ed60b196dbcda: > > Linux 4.16 (2018-04-01 14:20:27 -0700) > > are available in the git repository at: > > https://github.com/ojeda/linux.git tags

[GIT PULL] auxdisplay for v4.18-rc1

2018-06-07 Thread Miguel Ojeda
on select SYSCON/MFD_SYSCON Gustavo A. R. Silva (1): auxdisplay: cfag12864bfb: constify fb_fix_screeninfo and fb_var_screeninfo structures Miguel Ojeda (5): Doc: misc-devices: move lcd-panel-cgram.txt to auxdisplay/ MAINTAINERS: auxdisplay: remove obsolete webpages auxdisplay

[GIT PULL] auxdisplay for v4.18-rc1

2018-06-07 Thread Miguel Ojeda
on select SYSCON/MFD_SYSCON Gustavo A. R. Silva (1): auxdisplay: cfag12864bfb: constify fb_fix_screeninfo and fb_var_screeninfo structures Miguel Ojeda (5): Doc: misc-devices: move lcd-panel-cgram.txt to auxdisplay/ MAINTAINERS: auxdisplay: remove obsolete webpages auxdisplay

Re: [PATCH] clang-format: Set IndentWrappedFunctionNames false

2018-06-07 Thread Miguel Ojeda
On Wed, Jun 6, 2018 at 10:25 PM, Jason Gunthorpe wrote: > On Wed, Jun 06, 2018 at 01:18:59PM -0700, Joe Perches wrote: >> On Wed, 2018-06-06 at 14:15 -0600, Jason Gunthorpe wrote: >> > The true option causes this indenting for functions: >> > >> > static struct something_very_very_long * >> >

Re: [PATCH] clang-format: Set IndentWrappedFunctionNames false

2018-06-07 Thread Miguel Ojeda
On Wed, Jun 6, 2018 at 10:25 PM, Jason Gunthorpe wrote: > On Wed, Jun 06, 2018 at 01:18:59PM -0700, Joe Perches wrote: >> On Wed, 2018-06-06 at 14:15 -0600, Jason Gunthorpe wrote: >> > The true option causes this indenting for functions: >> > >> > static struct something_very_very_long * >> >

Re: [PATCH] clang-format: Set IndentWrappedFunctionNames false

2018-06-07 Thread Miguel Ojeda
On Wed, Jun 6, 2018 at 10:15 PM, Jason Gunthorpe wrote: > The true option causes this indenting for functions: > > static struct something_very_very_long * > function(void *arg) > { > > While a quick survey suggests that the usual Linux fallback is the GNU > style: > > static struct

Re: [PATCH] clang-format: Set IndentWrappedFunctionNames false

2018-06-07 Thread Miguel Ojeda
On Wed, Jun 6, 2018 at 10:15 PM, Jason Gunthorpe wrote: > The true option causes this indenting for functions: > > static struct something_very_very_long * > function(void *arg) > { > > While a quick survey suggests that the usual Linux fallback is the GNU > style: > > static struct

Re: [PATCH] clang-format: Set IndentWrappedFunctionNames false

2018-06-07 Thread Miguel Ojeda
On Wed, Jun 6, 2018 at 10:18 PM, Joe Perches wrote: > On Wed, 2018-06-06 at 14:15 -0600, Jason Gunthorpe wrote: >> The true option causes this indenting for functions: >> >> static struct something_very_very_long * >> function(void *arg) >> { >> >> While a quick survey suggests that the usual

Re: [PATCH] clang-format: Set IndentWrappedFunctionNames false

2018-06-07 Thread Miguel Ojeda
On Wed, Jun 6, 2018 at 10:18 PM, Joe Perches wrote: > On Wed, 2018-06-06 at 14:15 -0600, Jason Gunthorpe wrote: >> The true option causes this indenting for functions: >> >> static struct something_very_very_long * >> function(void *arg) >> { >> >> While a quick survey suggests that the usual

Re: [PATCH v2 2/3] power: supply: add cros-ec USBPD charger driver.

2018-04-30 Thread Miguel Ojeda
On Mon, Apr 30, 2018 at 3:14 PM, Enric Balletbo i Serra wrote: > From: Sameer Nanda > > This driver gets various bits of information about what is connected to > USB PD ports from the EC and converts that into power_supply properties. > >

Re: [PATCH v2 2/3] power: supply: add cros-ec USBPD charger driver.

2018-04-30 Thread Miguel Ojeda
On Mon, Apr 30, 2018 at 3:14 PM, Enric Balletbo i Serra wrote: > From: Sameer Nanda > > This driver gets various bits of information about what is connected to > USB PD ports from the EC and converts that into power_supply properties. > > Signed-off-by: Sameer Nanda > Signed-off-by: Enric

Re: DOS by unprivileged user

2018-04-30 Thread Miguel Ojeda
On Mon, Apr 30, 2018 at 12:00 PM, Ferry Toth wrote: > Op woensdag 25 april 2018 16:54:59 CEST schreef Alan Cox: >> > > I think memory allocation and io waits can't be decoupled from >> > > scheduling as they are now. >> > >> > The scheduler is not decoupled from either, it is

Re: DOS by unprivileged user

2018-04-30 Thread Miguel Ojeda
On Mon, Apr 30, 2018 at 12:00 PM, Ferry Toth wrote: > Op woensdag 25 april 2018 16:54:59 CEST schreef Alan Cox: >> > > I think memory allocation and io waits can't be decoupled from >> > > scheduling as they are now. >> > >> > The scheduler is not decoupled from either, it is intimately involved

Re: [PATCH 03/61] auxdisplay: simplify getting .drvdata

2018-04-19 Thread Miguel Ojeda
[CC'ing Linus W.] On Thu, Apr 19, 2018 at 4:05 PM, Wolfram Sang wrote: > We should get drvdata from struct device directly. Going via > platform_device is an unneeded step back and forth. > > Signed-off-by: Wolfram Sang Seems

Re: [PATCH 03/61] auxdisplay: simplify getting .drvdata

2018-04-19 Thread Miguel Ojeda
[CC'ing Linus W.] On Thu, Apr 19, 2018 at 4:05 PM, Wolfram Sang wrote: > We should get drvdata from struct device directly. Going via > platform_device is an unneeded step back and forth. > > Signed-off-by: Wolfram Sang Seems fine and other drivers in platform/ also call dev_get_drvdata

Re: [PATCH] net: phy: TLK10X initial driver submission

2018-04-19 Thread Miguel Ojeda
On Thu, Apr 19, 2018 at 10:28 AM, Måns Andersson wrote: > From: Mans Andersson > > Add suport for the TI TLK105 and TLK106 10/100Mbit ethernet phys. > Hi Mans, Some quick notes. > In addition the TLK10X needs to be removed from DP83848 driver as

Re: [PATCH] net: phy: TLK10X initial driver submission

2018-04-19 Thread Miguel Ojeda
On Thu, Apr 19, 2018 at 10:28 AM, Måns Andersson wrote: > From: Mans Andersson > > Add suport for the TI TLK105 and TLK106 10/100Mbit ethernet phys. > Hi Mans, Some quick notes. > In addition the TLK10X needs to be removed from DP83848 driver as the > power back off support is added here for

Re: [GIT PULL] auxdisplay for v4.17-rc1

2018-04-15 Thread Miguel Ojeda
On Sat, Apr 14, 2018 at 12:50 AM, Linus Torvalds <torva...@linux-foundation.org> wrote: > On Thu, Apr 12, 2018 at 11:37 AM, Miguel Ojeda > <miguel.ojeda.sando...@gmail.com> wrote: >> >> Please pull these fixes and cleanups for auxdisplay. > > As far as I can

Re: [GIT PULL] auxdisplay for v4.17-rc1

2018-04-15 Thread Miguel Ojeda
On Sat, Apr 14, 2018 at 12:50 AM, Linus Torvalds wrote: > On Thu, Apr 12, 2018 at 11:37 AM, Miguel Ojeda > wrote: >> >> Please pull these fixes and cleanups for auxdisplay. > > As far as I can tell, none of this has been in linux-next. > > By the end of the merge wi

[PATCH] MAINTAINERS: panel: Update file paths: drivers/{misc => auxdisplay}/

2018-04-12 Thread Miguel Ojeda
Cc: Willy Tarreau <w...@1wt.eu> Cc: Ksenija Stanojevic <ksenija.stanoje...@gmail.com> Signed-off-by: Miguel Ojeda <miguel.ojeda.sando...@gmail.com> --- MAINTAINERS | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/MAINTAINERS b/MAINTAINERS index f030e360

[PATCH] MAINTAINERS: panel: Update file paths: drivers/{misc => auxdisplay}/

2018-04-12 Thread Miguel Ojeda
Cc: Willy Tarreau Cc: Ksenija Stanojevic Signed-off-by: Miguel Ojeda --- MAINTAINERS | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/MAINTAINERS b/MAINTAINERS index f030e360f905..c42a4395b382 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -10420,8 +10420,8 @@ PARALLEL

[GIT PULL] auxdisplay for v4.17-rc1

2018-04-12 Thread Miguel Ojeda
Hi Linus, Please pull these fixes and cleanups for auxdisplay. They are recently rebased -- I am not on my main computer. Cheers, Miguel Ojeda The following changes since commit 0adb32858b0bddf4ada5f364a84ed60b196dbcda: Linux 4.16 (2018-04-01 14:20:27 -0700) are available in the git

[GIT PULL] auxdisplay for v4.17-rc1

2018-04-12 Thread Miguel Ojeda
Hi Linus, Please pull these fixes and cleanups for auxdisplay. They are recently rebased -- I am not on my main computer. Cheers, Miguel Ojeda The following changes since commit 0adb32858b0bddf4ada5f364a84ed60b196dbcda: Linux 4.16 (2018-04-01 14:20:27 -0700) are available in the git

Re: [PATCH 01/24] Add the ability to lock down access to the running kernel image

2018-04-11 Thread Miguel Ojeda
On Wed, Apr 11, 2018 at 7:37 PM, Randy Dunlap wrote: > On 04/11/2018 09:24 AM, David Howells wrote: > >> diff --git a/security/lock_down.c b/security/lock_down.c >> new file mode 100644 >> index ..f35ffdd096ad >> --- /dev/null >> +++ b/security/lock_down.c >> @@

Re: [PATCH 01/24] Add the ability to lock down access to the running kernel image

2018-04-11 Thread Miguel Ojeda
On Wed, Apr 11, 2018 at 7:37 PM, Randy Dunlap wrote: > On 04/11/2018 09:24 AM, David Howells wrote: > >> diff --git a/security/lock_down.c b/security/lock_down.c >> new file mode 100644 >> index ..f35ffdd096ad >> --- /dev/null >> +++ b/security/lock_down.c >> @@ -0,0 +1,65 @@ >> +/*

Re: [PATCH v2] auxdisplay: arm-charlcd: Fix struct charlcd doc line

2018-03-27 Thread Miguel Ojeda
On Tue, Mar 27, 2018 at 1:24 PM, Linus Walleij <linus.wall...@linaro.org> wrote: > On Tue, Mar 13, 2018 at 12:59 AM, Miguel Ojeda > <miguel.ojeda.sando...@gmail.com> wrote: > >> There was a missing first line and a missing member, >> which gave a warning und

Re: [PATCH v2] auxdisplay: arm-charlcd: Fix struct charlcd doc line

2018-03-27 Thread Miguel Ojeda
On Tue, Mar 27, 2018 at 1:24 PM, Linus Walleij wrote: > On Tue, Mar 13, 2018 at 12:59 AM, Miguel Ojeda > wrote: > >> There was a missing first line and a missing member, >> which gave a warning under W=1: >> >> CC drivers/auxdisplay/arm-charlcd.o >>

Re: [PATCH v6] kernel.h: Retain constant expression output for max()/min()

2018-03-27 Thread Miguel Ojeda
; */ > -#define __min(t1, t2, min1, min2, x, y) ({ \ > - t1 min1 = (x); \ > - t2 min2 = (y); \ > - (void) ( == );\ > - min1 < min2 ? m

Re: [PATCH v6] kernel.h: Retain constant expression output for max()/min()

2018-03-27 Thread Miguel Ojeda
\ > - (void) ( == );\ > - min1 < min2 ? min1 : min2; }) > +#define __is_constant(x) \ > + (sizeof(int) == sizeof(*(1 ? ((void*)((long)(x) * 0l)) : (int*)1))) I think Linus suggested __is_constant, but what about __is_constexpr

Re: [PATCH v2] clang-format: add configuration file

2018-03-18 Thread Miguel Ojeda
On Sun, Mar 18, 2018 at 7:26 PM, Joe Perches <j...@perches.com> wrote: > On Sun, 2018-03-18 at 18:16 +0100, Miguel Ojeda wrote: >> * Uses clang's tooling support behind the scenes to parse and rewrite >> the code. It is not based on ad-hoc regexps. > >

Re: [PATCH v2] clang-format: add configuration file

2018-03-18 Thread Miguel Ojeda
On Sun, Mar 18, 2018 at 7:26 PM, Joe Perches wrote: > On Sun, 2018-03-18 at 18:16 +0100, Miguel Ojeda wrote: >> * Uses clang's tooling support behind the scenes to parse and rewrite >> the code. It is not based on ad-hoc regexps. > > Did you look at the results of a

[PATCH v2] clang-format: add configuration file

2018-03-18 Thread Miguel Ojeda
: Andrew Morton <a...@linux-foundation.org> Signed-off-by: Miguel Ojeda <miguel.ojeda.sando...@gmail.com> --- .clang-format | 429 + .gitignore | 1 + Documentation/process/4.Coding.rst | 8 +

[PATCH v2] clang-format: add configuration file

2018-03-18 Thread Miguel Ojeda
out the tool at: https://clang.llvm.org/docs/ClangFormat.html https://clang.llvm.org/docs/ClangFormatStyleOptions.html Cc: Randy Dunlap Cc: Andy Whitcroft Cc: Joe Perches Cc: Jonathan Corbet Cc: Andrew Morton Signed-off-by: Miguel Ojeda --- .clang-format |

Re: [PATCH v5 0/2] Remove false-positive VLAs when using max()

2018-03-16 Thread Miguel Ojeda
On Fri, Mar 16, 2018 at 9:14 PM, Linus Torvalds <torva...@linux-foundation.org> wrote: > On Fri, Mar 16, 2018 at 1:03 PM, Miguel Ojeda > <miguel.ojeda.sando...@gmail.com> wrote: >>> >>> Kees - is there some online "gcc-4.4 checker" somewhere? This

Re: [PATCH v5 0/2] Remove false-positive VLAs when using max()

2018-03-16 Thread Miguel Ojeda
On Fri, Mar 16, 2018 at 9:14 PM, Linus Torvalds wrote: > On Fri, Mar 16, 2018 at 1:03 PM, Miguel Ojeda > wrote: >>> >>> Kees - is there some online "gcc-4.4 checker" somewhere? This does >>> seem to work with my gcc. I actually tested some of thos

Re: [PATCH v5 0/2] Remove false-positive VLAs when using max()

2018-03-16 Thread Miguel Ojeda
On Fri, Mar 16, 2018 at 9:14 PM, Linus Torvalds <torva...@linux-foundation.org> wrote: > On Fri, Mar 16, 2018 at 1:03 PM, Miguel Ojeda > <miguel.ojeda.sando...@gmail.com> wrote: >>> >>> Kees - is there some online "gcc-4.4 checker" somewhere? This

Re: [PATCH v5 0/2] Remove false-positive VLAs when using max()

2018-03-16 Thread Miguel Ojeda
On Fri, Mar 16, 2018 at 9:14 PM, Linus Torvalds wrote: > On Fri, Mar 16, 2018 at 1:03 PM, Miguel Ojeda > wrote: >>> >>> Kees - is there some online "gcc-4.4 checker" somewhere? This does >>> seem to work with my gcc. I actually tested some of thos

Re: [PATCH v5 0/2] Remove false-positive VLAs when using max()

2018-03-16 Thread Miguel Ojeda
On Fri, Mar 16, 2018 at 8:27 PM, Linus Torvalds wrote: > On Fri, Mar 16, 2018 at 10:55 AM, Al Viro wrote: >> >> That's not them, that's C standard regarding ICE. > > Yes. The C standard talks about "integer constant expression". I know. >

Re: [PATCH v5 0/2] Remove false-positive VLAs when using max()

2018-03-16 Thread Miguel Ojeda
On Fri, Mar 16, 2018 at 8:27 PM, Linus Torvalds wrote: > On Fri, Mar 16, 2018 at 10:55 AM, Al Viro wrote: >> >> That's not them, that's C standard regarding ICE. > > Yes. The C standard talks about "integer constant expression". I know. > It's come up in this very thread before. > > The C

Re: [PATCH v4 1/2] kernel.h: Introduce const_max() for VLA removal

2018-03-15 Thread Miguel Ojeda
On Fri, Mar 16, 2018 at 12:49 AM, Kees Cook wrote: > On Thu, Mar 15, 2018 at 4:46 PM, Linus Torvalds > wrote: >> What I'm *not* so much ok with is "const_max(5,sizeof(x))" erroring >> out, or silently causing insane behavior due to hidden

Re: [PATCH v4 1/2] kernel.h: Introduce const_max() for VLA removal

2018-03-15 Thread Miguel Ojeda
On Fri, Mar 16, 2018 at 12:49 AM, Kees Cook wrote: > On Thu, Mar 15, 2018 at 4:46 PM, Linus Torvalds > wrote: >> What I'm *not* so much ok with is "const_max(5,sizeof(x))" erroring >> out, or silently causing insane behavior due to hidden subtle type >> casts.. > > Yup! I like it as an explicit

Re: [PATCH v4 1/2] kernel.h: Introduce const_max() for VLA removal

2018-03-15 Thread Miguel Ojeda
On Fri, Mar 16, 2018 at 12:08 AM, Miguel Ojeda <miguel.ojeda.sando...@gmail.com> wrote: > On Thu, Mar 15, 2018 at 11:58 PM, Miguel Ojeda > <miguel.ojeda.sando...@gmail.com> wrote: >> On Thu, Mar 15, 2018 at 11:46 PM, Kees Cook <keesc...@chromium.org> wrote: &

Re: [PATCH v4 1/2] kernel.h: Introduce const_max() for VLA removal

2018-03-15 Thread Miguel Ojeda
On Fri, Mar 16, 2018 at 12:08 AM, Miguel Ojeda wrote: > On Thu, Mar 15, 2018 at 11:58 PM, Miguel Ojeda > wrote: >> On Thu, Mar 15, 2018 at 11:46 PM, Kees Cook wrote: >>> >>> By using this eye-bleed: >>> >>> size_t __error_not_const_arg(void) \ &g

Re: [PATCH v4 1/2] kernel.h: Introduce const_max() for VLA removal

2018-03-15 Thread Miguel Ojeda
On Thu, Mar 15, 2018 at 11:58 PM, Miguel Ojeda <miguel.ojeda.sando...@gmail.com> wrote: > On Thu, Mar 15, 2018 at 11:46 PM, Kees Cook <keesc...@chromium.org> wrote: >> >> By using this eye-bleed: >> >> size_t __error_not_const_arg(void) \ >> __compile

Re: [PATCH v4 1/2] kernel.h: Introduce const_max() for VLA removal

2018-03-15 Thread Miguel Ojeda
On Thu, Mar 15, 2018 at 11:58 PM, Miguel Ojeda wrote: > On Thu, Mar 15, 2018 at 11:46 PM, Kees Cook wrote: >> >> By using this eye-bleed: >> >> size_t __error_not_const_arg(void) \ >> __compiletime_error("const_max() used with non-compile-time constant arg

Re: [PATCH v4 1/2] kernel.h: Introduce const_max() for VLA removal

2018-03-15 Thread Miguel Ojeda
On Thu, Mar 15, 2018 at 11:46 PM, Kees Cook wrote: > On Thu, Mar 15, 2018 at 3:23 PM, Linus Torvalds > wrote: >> On Thu, Mar 15, 2018 at 3:16 PM, Kees Cook wrote: >>> >>> size_t __error_not_const_arg(void) \ >>>

Re: [PATCH v4 1/2] kernel.h: Introduce const_max() for VLA removal

2018-03-15 Thread Miguel Ojeda
On Thu, Mar 15, 2018 at 11:46 PM, Kees Cook wrote: > On Thu, Mar 15, 2018 at 3:23 PM, Linus Torvalds > wrote: >> On Thu, Mar 15, 2018 at 3:16 PM, Kees Cook wrote: >>> >>> size_t __error_not_const_arg(void) \ >>> __compiletime_error("const_max() used with non-compile-time constant arg"); >>>

Re: [GIT PULL] auxdisplay for v4.16-rc6

2018-03-14 Thread Miguel Ojeda
On Wed, Mar 14, 2018 at 5:56 PM, Linus Torvalds <torva...@linux-foundation.org> wrote: > On Tue, Mar 13, 2018 at 11:46 AM, Miguel Ojeda > <miguel.ojeda.sando...@gmail.com> wrote: >> >> This is my first pull request, so if there is anything wrong, please l

Re: [GIT PULL] auxdisplay for v4.16-rc6

2018-03-14 Thread Miguel Ojeda
On Wed, Mar 14, 2018 at 5:56 PM, Linus Torvalds wrote: > On Tue, Mar 13, 2018 at 11:46 AM, Miguel Ojeda > wrote: >> >> This is my first pull request, so if there is anything wrong, please let >> me know! > > The commits in there looks fine, but I have to admit to

Re: [PATCH] drivers: net: wireless: ath: ath9: dfs: remove VLA usage

2018-03-13 Thread Miguel Ojeda
On Sun, Mar 11, 2018 at 12:12 AM, Kees Cook wrote: > > The problem is that it's not a "constant expression", so the compiler > frontend still yells about it under -Wvla. I would characterize this > mainly as a fix for "accidental VLA" or "misdetected VLA" or something >

Re: [PATCH] drivers: net: wireless: ath: ath9: dfs: remove VLA usage

2018-03-13 Thread Miguel Ojeda
On Sun, Mar 11, 2018 at 12:12 AM, Kees Cook wrote: > > The problem is that it's not a "constant expression", so the compiler > frontend still yells about it under -Wvla. I would characterize this > mainly as a fix for "accidental VLA" or "misdetected VLA" or something > like that. AIUI, there

Re: [PATCH] clang-format: add configuration file

2018-03-13 Thread Miguel Ojeda
On Wed, Mar 14, 2018 at 1:18 AM, Miguel Ojeda <miguel.ojeda.sando...@gmail.com> wrote: > > Since we seem to agree on having this, I will send a v2 after I try a > few experiments to try to reduce more the produced diffs, explain > things better in Documentation/, add more comm

Re: [PATCH] clang-format: add configuration file

2018-03-13 Thread Miguel Ojeda
On Wed, Mar 14, 2018 at 1:18 AM, Miguel Ojeda wrote: > > Since we seem to agree on having this, I will send a v2 after I try a > few experiments to try to reduce more the produced diffs, explain > things better in Documentation/, add more comments in the config file > and send

Re: [PATCH] clang-format: add configuration file

2018-03-13 Thread Miguel Ojeda
On Tue, Mar 13, 2018 at 11:29 PM, Joe Perches <j...@perches.com> wrote: > On Tue, 2018-03-13 at 22:52 +0100, Miguel Ojeda wrote: >> On Tue, Mar 13, 2018 at 10:00 PM, Andrew Morton <a...@linux-foundation.org> >> wrote: >> > On Tue, 13 Mar 2018 00:39:52 +0100 Mi

Re: [PATCH] clang-format: add configuration file

2018-03-13 Thread Miguel Ojeda
On Tue, Mar 13, 2018 at 11:29 PM, Joe Perches wrote: > On Tue, 2018-03-13 at 22:52 +0100, Miguel Ojeda wrote: >> On Tue, Mar 13, 2018 at 10:00 PM, Andrew Morton >> wrote: >> > On Tue, 13 Mar 2018 00:39:52 +0100 Miguel Ojeda >> > wrote: >> >

Re: [PATCH] clang-format: add configuration file

2018-03-13 Thread Miguel Ojeda
On Tue, Mar 13, 2018 at 10:00 PM, Andrew Morton <a...@linux-foundation.org> wrote: > On Tue, 13 Mar 2018 00:39:52 +0100 Miguel Ojeda > <miguel.ojeda.sando...@gmail.com> wrote: > >> --- a/Documentation/process/4.Coding.rst >> +++ b/Documentation/process/4.Coding.rs

Re: [PATCH] clang-format: add configuration file

2018-03-13 Thread Miguel Ojeda
On Tue, Mar 13, 2018 at 10:00 PM, Andrew Morton wrote: > On Tue, 13 Mar 2018 00:39:52 +0100 Miguel Ojeda > wrote: > >> --- a/Documentation/process/4.Coding.rst >> +++ b/Documentation/process/4.Coding.rst >> @@ -58,6 +58,12 @@ can never be transgressed. If there

[GIT PULL] auxdisplay for v4.16-rc6

2018-03-13 Thread Miguel Ojeda
used GitHub as well for the same reason. Cheers, Miguel Ojeda The following changes since commit 0c8efd610b58cb23cefdfa12015799079aef94ae: Linux 4.16-rc5 (2018-03-11 17:25:09 -0700) are available in the git repository at: https://github.com/ojeda/linux.git tags/auxdisplay-for-linus-v4.16

[GIT PULL] auxdisplay for v4.16-rc6

2018-03-13 Thread Miguel Ojeda
used GitHub as well for the same reason. Cheers, Miguel Ojeda The following changes since commit 0c8efd610b58cb23cefdfa12015799079aef94ae: Linux 4.16-rc5 (2018-03-11 17:25:09 -0700) are available in the git repository at: https://github.com/ojeda/linux.git tags/auxdisplay-for-linus-v4.16

Re: [PATCH] Support the nonstring variable attribute (gcc >= 8)

2018-03-13 Thread Miguel Ojeda
On Tue, Mar 13, 2018 at 4:41 PM, Martin Sebor wrote: > Martin Sebor also asked me about this, he's the one that worked on > the gcc code that introduced the warning. Sorry for not replying > earlier. > Maybe you can pass this to him? (maybe open a bug

Re: [PATCH] Support the nonstring variable attribute (gcc >= 8)

2018-03-13 Thread Miguel Ojeda
On Tue, Mar 13, 2018 at 4:41 PM, Martin Sebor wrote: > Martin Sebor also asked me about this, he's the one that worked on > the gcc code that introduced the warning. Sorry for not replying > earlier. > Maybe you can pass this to him? (maybe open a bug in gcc's bugzilla?)

Re: [PATCH] auxdisplay: Replace licenses with SPDX identifiers

2018-03-12 Thread Miguel Ojeda
un, Feb 18, 2018 at 8:04 PM, Philippe Ombredanne >>> <pombreda...@nexb.com> wrote: >>> > On Sat, Feb 17, 2018 at 8:39 PM, Miguel Ojeda >>> > <miguel.ojeda.sando...@gmail.com> wrote: >>> > > Cc: Willy Tarreau <w...@1wt.eu> >>&

Re: [PATCH] auxdisplay: Replace licenses with SPDX identifiers

2018-03-12 Thread Miguel Ojeda
t;>> wrote: >>> > On Sat, Feb 17, 2018 at 8:39 PM, Miguel Ojeda >>> > wrote: >>> > > Cc: Willy Tarreau >>> > > Cc: Geert Uytterhoeven >>> > > Cc: Linus Walleij >>> > > Cc: Robin van der Gracht >>> > > Cc: Paul Burton >>> > > Signed-off-by: Miguel Ojeda >>> > > --- Pinging Paul Burton in a couple of emails more... Cheers, Miguel

[PATCH] Doc: misc-devices: move lcd-panel-cgram.txt to auxdisplay/

2018-03-12 Thread Miguel Ojeda
Commit 7005b58458e4beecaf5efacb872c456bc7d3541a ("Staging: add lcd-panel driver") introduced the panel driver, which is now in drivers/auxdisplay. Cc: Willy Tarreau <w...@1wt.eu> Cc: Jonathan Corbet <cor...@lwn.net> Signed-off-by: Miguel Ojeda <miguel.ojeda.sando...@gmai

[PATCH] Doc: misc-devices: move lcd-panel-cgram.txt to auxdisplay/

2018-03-12 Thread Miguel Ojeda
Commit 7005b58458e4beecaf5efacb872c456bc7d3541a ("Staging: add lcd-panel driver") introduced the panel driver, which is now in drivers/auxdisplay. Cc: Willy Tarreau Cc: Jonathan Corbet Signed-off-by: Miguel Ojeda --- Documentation/{misc-devices => auxdisplay}/lcd-panel-cgram.tx

[PATCH v2] auxdisplay: arm-charlcd: Fix struct charlcd doc line

2018-03-12 Thread Miguel Ojeda
Walleij <tr...@df.lth.se> Cc: Randy Dunlap <rdun...@infradead.org> Signed-off-by: Miguel Ojeda <miguel.ojeda.sando...@gmail.com> --- drivers/auxdisplay/arm-charlcd.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/auxdisplay/arm-charlcd.c b/drivers/auxdisplay/a

[PATCH v2] auxdisplay: arm-charlcd: Fix struct charlcd doc line

2018-03-12 Thread Miguel Ojeda
Walleij Cc: Randy Dunlap Signed-off-by: Miguel Ojeda --- drivers/auxdisplay/arm-charlcd.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/auxdisplay/arm-charlcd.c b/drivers/auxdisplay/arm-charlcd.c index b3176ee92b90..dde180995582 100644 --- a/drivers/auxdisplay/arm-charlcd.c +++ b

[PATCH] clang-format: add configuration file

2018-03-12 Thread Miguel Ojeda
tml https://clang.llvm.org/docs/ClangFormatStyleOptions.html Cc: Randy Dunlap <rdun...@infradead.org> Cc: Andy Whitcroft <a...@canonical.com> Cc: Joe Perches <j...@perches.com> Cc: Jonathan Corbet <cor...@lwn.net> Cc: Andrew Morton <a...@linux-foundation.or

[PATCH] clang-format: add configuration file

2018-03-12 Thread Miguel Ojeda
tml https://clang.llvm.org/docs/ClangFormatStyleOptions.html Cc: Randy Dunlap Cc: Andy Whitcroft Cc: Joe Perches Cc: Jonathan Corbet Cc: Andrew Morton Signed-off-by: Miguel Ojeda --- .clang-format | 107 + .gitign

Re: [PATCH v3] kernel.h: Skip single-eval logic on literals in min()/max()

2018-03-10 Thread Miguel Ojeda
On Sat, Mar 10, 2018 at 6:51 PM, Linus Torvalds wrote: > > So in *historical* context - when a compiler didn't do variable length > arrays at all - the original semantics of C "constant expressions" > actually make a ton of sense. > > You can basically think of a

Re: [PATCH v3] kernel.h: Skip single-eval logic on literals in min()/max()

2018-03-10 Thread Miguel Ojeda
On Sat, Mar 10, 2018 at 6:51 PM, Linus Torvalds wrote: > > So in *historical* context - when a compiler didn't do variable length > arrays at all - the original semantics of C "constant expressions" > actually make a ton of sense. > > You can basically think of a constant expression as something

Re: [PATCH v3] kernel.h: Skip single-eval logic on literals in min()/max()

2018-03-10 Thread Miguel Ojeda
On Sat, Mar 10, 2018 at 5:30 PM, Linus Torvalds wrote: > On Sat, Mar 10, 2018 at 7:33 AM, Kees Cook wrote: >> >> Alright, I'm giving up on fixing max(). I'll go back to STACK_MAX() or >> some other name for the simple macro. Bleh. > > Oh, and

Re: [PATCH v3] kernel.h: Skip single-eval logic on literals in min()/max()

2018-03-10 Thread Miguel Ojeda
On Sat, Mar 10, 2018 at 5:30 PM, Linus Torvalds wrote: > On Sat, Mar 10, 2018 at 7:33 AM, Kees Cook wrote: >> >> Alright, I'm giving up on fixing max(). I'll go back to STACK_MAX() or >> some other name for the simple macro. Bleh. > > Oh, and I'm starting to see the real problem. > > It's not

Re: [PATCH v3] kernel.h: Skip single-eval logic on literals in min()/max()

2018-03-09 Thread Miguel Ojeda
On Sat, Mar 10, 2018 at 7:10 AM, Miguel Ojeda <miguel.ojeda.sando...@gmail.com> wrote: > On Sat, Mar 10, 2018 at 4:11 AM, Randy Dunlap <rdun...@infradead.org> wrote: >> On 03/09/2018 04:07 PM, Andrew Morton wrote: >>> On Fri, 9 Mar 2018 12:05:36 -0800 Kees Cook

Re: [PATCH v3] kernel.h: Skip single-eval logic on literals in min()/max()

2018-03-09 Thread Miguel Ojeda
On Sat, Mar 10, 2018 at 7:10 AM, Miguel Ojeda wrote: > On Sat, Mar 10, 2018 at 4:11 AM, Randy Dunlap wrote: >> On 03/09/2018 04:07 PM, Andrew Morton wrote: >>> On Fri, 9 Mar 2018 12:05:36 -0800 Kees Cook wrote: >>> >>>> When max() is used in stack arra

Re: [PATCH v3] kernel.h: Skip single-eval logic on literals in min()/max()

2018-03-09 Thread Miguel Ojeda
On Sat, Mar 10, 2018 at 4:11 AM, Randy Dunlap wrote: > On 03/09/2018 04:07 PM, Andrew Morton wrote: >> On Fri, 9 Mar 2018 12:05:36 -0800 Kees Cook wrote: >> >>> When max() is used in stack array size calculations from literal values >>> (e.g. "char

Re: [PATCH v3] kernel.h: Skip single-eval logic on literals in min()/max()

2018-03-09 Thread Miguel Ojeda
On Sat, Mar 10, 2018 at 4:11 AM, Randy Dunlap wrote: > On 03/09/2018 04:07 PM, Andrew Morton wrote: >> On Fri, 9 Mar 2018 12:05:36 -0800 Kees Cook wrote: >> >>> When max() is used in stack array size calculations from literal values >>> (e.g. "char foo[max(sizeof(struct1), sizeof(struct2))]",

Re: [PATCH V2 2/3] efi: Introduce efi_rts_workqueue and some infrastructure to invoke all efi_runtime_services()

2018-03-08 Thread Miguel Ojeda
On Thu, Mar 8, 2018 at 5:22 AM, Prakhya, Sai Praneeth wrote: >> > +struct workqueue_struct *efi_rts_wq; >> > + >> > static bool disable_runtime; >> > static int __init setup_noefi(char *arg) { @@ -329,6 +331,19 @@ >> > static int __init efisubsys_init(void) >> >

<    3   4   5   6   7   8   9   10   11   >