mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Marcel Holtmann <marcel@holtmann.org>
To: Anders Blomdell <anders.blomdell@control.lth.se>
Cc: linux-kernel@vger.kernel.org, Manuel Estrada Sainz <ranty@debian.org>
Subject: Re: [PATCH] Documentation/firmware_class/firmware_sample_driver.c
Date: Wed, 27 Jun 2007 19:49:29 +0200	[thread overview]
Message-ID: <1182966569.9499.1.camel@aeonflux.holtmann.net> (raw)
In-Reply-To: <46827B20.6000501@control.lth.se>

Hi Anders,

> Signed-off-by: Anders Blomdell <anders.blomdell@control.lth.se>
> 
> Minor modifications to make the example load and unload without Oops
> 
> This is what unpatched version generates with 2.6.21.3
> 
> kernel: Oops: 0000 [#2]
> ...
> kernel: Call Trace:
> kernel:  [<c04ae541>] sysfs_create_dir+0x49/0x63
> kernel:  [<c04e76ae>] kobject_shadow_add+0xd5/0x17d
> kernel:  [<c04e7908>] kobject_set_name+0x2b/0x92
> kernel:  [<c0556444>] device_add+0x9a/0x58e
> kernel:  [<c0620b65>] klist_init+0x23/0x2e
> kernel:  [<c055bfee>] _request_firmware+0x116/0x29f
> kernel:  [<c062149f>] wait_for_completion+0x8b/0x93
> kernel:  [<c055c20b>] request_firmware+0xf/0x11
> kernel:  [<e09420d9>] sample_init+0x59/0xc0 [firmware_sample_driver]
> kernel:  [<c0446c92>] sys_init_module+0x16b7/0x17ee
> kernel:  [<c04294de>] printk+0x0/0x1f
> kernel:  [<c0488436>] mntput_no_expire+0x11/0x6e
> kernel:  [<c0404fa8>] syscall_call+0x7/0xb
> 
> 
> 
> diff -u Documentation/firmware_class/firmware_sample_driver.c
> /tmp/fw/firmware_sample_driver.c
> --- Documentation/firmware_class/firmware_sample_driver.c       2007-05-24
> 23:22:47.000000000 +0200
> +++ /tmp/fw/firmware_sample_driver.c    2007-06-27 16:51:16.000000000 +0200
> @@ -15,11 +15,16 @@
> 
>  #include "linux/firmware.h"
> 
> +static void ghost_release(struct device *dev)
> +{
> +       printk(KERN_DEBUG "firmware_sample_driver: ghost_release\n");
> +}
> +

I know it is a sample driver, but you can't do that. You have to
allocate the device and then free it here.

Regards

Marcel



  reply	other threads:[~2007-06-27 17:51 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-06-27 14:58 Anders Blomdell
2007-06-27 17:49 ` Marcel Holtmann [this message]
2007-06-28  8:47   ` Anders Blomdell
2007-06-28 10:35 ` Satyam Sharma
2007-06-29 17:49   ` Anders Blomdell

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1182966569.9499.1.camel@aeonflux.holtmann.net \
    --to=marcel@holtmann.org \
    --cc=anders.blomdell@control.lth.se \
    --cc=linux-kernel@vger.kernel.org \
    --cc=ranty@debian.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome