lkml.org 
[lkml]   [2001]   [May]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
SubjectRe: 2.4.4-ac4 - oops on unload "cdrom" module
Date

> This oops happens when I run "rmmod cdrom" on a 2.4.4-ac4 kernel with
> CONFIG_SYSCTL enabled. It doesn't happen if CONFIG_SYSCTL is disabled.
>
> sr_mod isn't loaded at this point. Reference to sd_mod looks weird. After
> this oops the "cdrom" module remains in memory in the "deleted" state.

> Unable to handle kernel NULL pointer dereference at virtual address 00000008
[...]
> >>EIP; c0118051 <unregister_sysctl_table+5/2c> <=====

The following patch fixes unloading of cdrom module when no cdrom driver
loaded (2.4.5-pre, 2.4.4-ac):

--- drivers/cdrom/cdrom.c.old Fri May 4 22:44:31 2001
+++ drivers/cdrom/cdrom.c Fri May 4 22:54:36 2001
@@ -2698,7 +2698,8 @@

static void cdrom_sysctl_unregister(void)
{
- unregister_sysctl_table(cdrom_sysctl_header);
+ if (cdrom_sysctl_header)
+ unregister_sysctl_table(cdrom_sysctl_header);
}

#endif /* CONFIG_SYSCTL */

Andrzej


--
=======================================================================
Andrzej M. Krzysztofowicz ankry@mif.pg.gda.pl
tel. (0-58) 347 14 61
Wydz.Fizyki Technicznej i Matematyki Stosowanej Politechniki Gdanskiej
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
\
 
 \ /
  Last update: 2005-03-22 12:52    [W:0.037 / U:7.664 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site