[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
BOUNCE rtl@rtlinux.org: Approval required: Non-member submissionfrom [=?iso-8859-1?Q?S=E9bastien?= GAUME<sgaume@b2i-toulous (fwd)
- To: rtl@rtlinux.org
- Subject: BOUNCE rtl@rtlinux.org: Approval required: Non-member submissionfrom [=?iso-8859-1?Q?S=E9bastien?= GAUME<sgaume@b2i-toulous (fwd)
- From: Der Herr Hofrat <der.herr@hofr.at>
- Date: Fri, 11 May 2001 09:46:46 +0200 (CEST)
>From owner-rtl Fri May 11 02:46:36 2001
Received: from mail.b2i-toulouse.com (host.97.67.23.62.rev.coltfrance.com [62.23.67.97])
by hq.fsmlabs.com (8.11.2/8.11.2) with ESMTP id f4B8kYJ04225;
Fri, 11 May 2001 02:46:35 -0600
Received: from b2i-toulouse.com (wilson.b2i-toulouse.com [192.168.0.25] (may be forged))
by mail.b2i-toulouse.com (8.11.0/8.11.0) with ESMTP id f4B7cKd06690;
Fri, 11 May 2001 09:38:20 +0200
Message-ID: <3AFBA65E.C9FD0F47@b2i-toulouse.com>
Date: Fri, 11 May 2001 10:44:14 +0200
From: =?iso-8859-1?Q?S=E9bastien?= GAUME <sgaume@b2i-toulouse.com>
Organization: b2i-toulouse
X-Mailer: Mozilla 4.75 [fr] (WinNT; U)
X-Accept-Language: fr
MIME-Version: 1.0
To: rtl@fsmlabs.com, rtl@rtlinux.org
Subject: Mbuff module unloadable
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Hello,
I am working with the mbuff module but I have trouble with it since it
is sometimes impossible to remove it. This is due to the fact that the
module is still used as the lsmod command shows me. But why is it still
used ?
I use shm_allocate in the init_module and shm_deallocate in the
cleanup_module. The only one thing (according to me) that may cause
trouble is that casts are made while using shm_allocate and
shm_deallocate. Let's have a look at the following code :
[...]
static char * name_mem = "NAME_MEM";
static int size_mem = 1024*1024;
static char message[5];
[...]
int init_module(void)
{
[...]
shm_allocate(name_mem,size_mem,(void**)&message);
[...]
}
void cleanup_module(void)
{
[...]
shm_deallocate((void*)message);
[...]
}
It seems to me that shm_deallocate((void*)message) doesn't work
properly, because of the cast. But why ? The trouble may come from
somewhere else, but I have no idea.
Answers are welcome. Thank you for your help.
Sebastien