Re: Possible broken MM code in dell-laptop.c?

2015-06-18 Thread Darren Hart
On Wed, Jun 17, 2015 at 09:19:39AM +0200, Michal Hocko wrote: > On Tue 16-06-15 20:43:34, Darren Hart wrote: > [...] > > Michal - thanks for the context. > > > > I'm surprised by your recommendation to use __free_page() out here in > > platform > > driver land. > > > > I'd also prefer that the d

Re: Possible broken MM code in dell-laptop.c?

2015-06-17 Thread Michal Hocko
On Tue 16-06-15 20:43:34, Darren Hart wrote: [...] > Michal - thanks for the context. > > I'm surprised by your recommendation to use __free_page() out here in platform > driver land. > > I'd also prefer that the driver consistently free the same address to avoid > confusion. > > For these reaso

Re: Possible broken MM code in dell-laptop.c?

2015-06-16 Thread Darren Hart
On Tue, Jun 16, 2015 at 09:15:23AM +0200, Pali Rohár wrote: > On Tuesday 16 June 2015 08:33:46 Michal Hocko wrote: > > On Mon 15-06-15 23:27:59, Pali Rohár wrote: > > > On Monday 15 June 2015 23:18:16 Michal Hocko wrote: > > > > On Sun 14-06-15 11:05:07, Pali Rohár wrote: > > > > > Hello, > > > > >

Re: Possible broken MM code in dell-laptop.c?

2015-06-16 Thread Pavel Machek
On Mon 2015-06-15 22:42:30, Pali Rohár wrote: > On Monday 15 June 2015 22:36:45 Darren Hart wrote: > > On Sun, Jun 14, 2015 at 11:05:07AM +0200, Pali Rohár wrote: > > > Hello, > > > > > > in drivers/platform/x86/dell-laptop.c is this part of code: > > > > > > static int __init dell_init(void) > >

Re: Possible broken MM code in dell-laptop.c?

2015-06-16 Thread Michal Hocko
On Tue 16-06-15 09:15:23, Pali Rohár wrote: [...] > Michal, thank you for explaining this situation! > > Darren, I will prepare patch which will fix code and use __free_page(). > > (Btw, execution on fail_rfkill label caused kernel panic) I am sorry, I could have made it more clear in the very f

Re: Possible broken MM code in dell-laptop.c?

2015-06-16 Thread Pali Rohár
On Tuesday 16 June 2015 08:33:46 Michal Hocko wrote: > On Mon 15-06-15 23:27:59, Pali Rohár wrote: > > On Monday 15 June 2015 23:18:16 Michal Hocko wrote: > > > On Sun 14-06-15 11:05:07, Pali Rohár wrote: > > > > Hello, > > > > > > > > in drivers/platform/x86/dell-laptop.c is this part of code: >

Re: Possible broken MM code in dell-laptop.c?

2015-06-15 Thread Michal Hocko
On Mon 15-06-15 23:27:59, Pali Rohár wrote: > On Monday 15 June 2015 23:18:16 Michal Hocko wrote: > > On Sun 14-06-15 11:05:07, Pali Rohár wrote: > > > Hello, > > > > > > in drivers/platform/x86/dell-laptop.c is this part of code: > > > > > > static int __init dell_init(void) > > > { > > > ... >

Re: Possible broken MM code in dell-laptop.c?

2015-06-15 Thread Pali Rohár
On Monday 15 June 2015 23:18:16 Michal Hocko wrote: > On Sun 14-06-15 11:05:07, Pali Rohár wrote: > > Hello, > > > > in drivers/platform/x86/dell-laptop.c is this part of code: > > > > static int __init dell_init(void) > > { > > ... > > > > /* > > > > * Allocate buffer below 4GB fo

Re: Possible broken MM code in dell-laptop.c?

2015-06-15 Thread Michal Hocko
On Sun 14-06-15 11:05:07, Pali Rohár wrote: > Hello, > > in drivers/platform/x86/dell-laptop.c is this part of code: > > static int __init dell_init(void) > { > ... > /* >* Allocate buffer below 4GB for SMI data--only 32-bit physical addr >* is passed to SMI handler. >

Re: Possible broken MM code in dell-laptop.c?

2015-06-15 Thread Pali Rohár
On Monday 15 June 2015 22:36:45 Darren Hart wrote: > On Sun, Jun 14, 2015 at 11:05:07AM +0200, Pali Rohár wrote: > > Hello, > > > > in drivers/platform/x86/dell-laptop.c is this part of code: > > > > static int __init dell_init(void) > > { > > ... > > > > /* > > > > * Allocate buff

Re: Possible broken MM code in dell-laptop.c?

2015-06-15 Thread Darren Hart
On Sun, Jun 14, 2015 at 11:05:07AM +0200, Pali Rohár wrote: > Hello, > > in drivers/platform/x86/dell-laptop.c is this part of code: > > static int __init dell_init(void) > { > ... > /* >* Allocate buffer below 4GB for SMI data--only 32-bit physical addr >* is passed to SMI

Possible broken MM code in dell-laptop.c?

2015-06-14 Thread Pali Rohár
Hello, in drivers/platform/x86/dell-laptop.c is this part of code: static int __init dell_init(void) { ... /* * Allocate buffer below 4GB for SMI data--only 32-bit physical addr * is passed to SMI handler. */ bufferpage = alloc_page(GFP_KERNEL | GFP_DMA3