lkml.org 
[lkml]   [2014]   [Sep]   [30]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [PATCH v2] i2c: move acpi code back into the core
Date
On Tuesday, September 30, 2014 08:46:07 PM Jean Delvare wrote:
> On Tue, 30 Sep 2014 19:03:52 +0300, Mika Westerberg wrote:
> > On Tue, Sep 30, 2014 at 12:55:20PM +0200, Jean Delvare wrote:
> > > The only thing which I find curious is that ACPI_I2C_OPREGION depends
> > > on I2C=y. Is this limitation a leftover from when the code was split to
> > > a separate file? It builds just fine with I2C=m, and I can't see why it
> > > wouldn't work. I have a patch to enable that, I can send it if it is
> > > the right thing to do. But maybe I'm missing something?
> >
> > I think reason for the limitation is that if there happens to be some
> > AML code that is currently using the I2C operation region and the user
> > decides to unload the i2c-core.ko module or along those lines.
>
> If that's the reason then shouldn't it be addressed by proper reference
> counting instead? We could simply increase the module reference count
> when entering the critical section, and decrease it when we're done.

That is not so simple in practice, because the code containing the
critical sections in question is AML and not part of the kernel.

--
I speak only for myself.
Rafael J. Wysocki, Intel Open Source Technology Center.


\
 
 \ /
  Last update: 2014-09-30 22:41    [W:0.052 / U:0.292 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site