Re: [RFC: 2.6 patch] kernel/sys.c: remove unused exports

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Adrian Bunk <[email protected]> writes:

> On Thu, Jun 29, 2006 at 01:06:33PM -0700, Andrew Morton wrote:
>> On Thu, 29 Jun 2006 21:58:28 +0200
>> Adrian Bunk <[email protected]> wrote:
>> 
>> > On Thu, Jun 29, 2006 at 12:44:00PM -0700, Andrew Morton wrote:
>> > > On Thu, 29 Jun 2006 12:36:08 -0700
>> > > Andrew Morton <[email protected]> wrote:
>> > > 
>> > > > On Thu, 29 Jun 2006 21:19:40 +0200
>> > > > Adrian Bunk <[email protected]> wrote:
>> > > > 
>> > > > > - EXPORT_SYMBOL_GPL's:
>> > > > >   - kernel_restart
>> > > > >   - kernel_halt
>> > > > 

So I can comment on kernel_restart and kernel_halt.
I think I come about as close as it comes to a maintainer
of the reboot infrastructure, and I did write those two functions.

The problem is they were created to address is several different
places in the kernel were performing reboots or halts and
did it inconsistently.  with the result that most localized bug
fixes would trigger a bug in another code path.

At the time the functions machine_halt, and machine_reboot were
exported functions.  So when I did the conversions I preserved
the presence of the export.

After all of the dust settled I think only the swap suspend
code calls into that and that code can't be built modular
so I think removing the exports are ok.

The other places that were calling into these code paths
are now calling emergency_restart().

Enough dust has settled and I can't spot any inappropriate
users in the kernel right now so removing those two exports sounds
fine with me.  We can always add them again if we get modular users.

As long as we are not encouraging people to reinvent this interface
badly again  I have no problems.  If I could think of an appropriate
reason why people would calls these interfaces other than in a watchdog driver
I would worry about people calling emergency_restart when the really wanted
kernel_restart, but didn't because they didn't have the export available.

Eric

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux