linux-iio.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jonathan Cameron <jic23@cam.ac.uk>
To: Ge Gao <ggao@invensense.com>
Cc: linux-iio@vger.kernel.org
Subject: Re: trigger removal problem.
Date: Fri, 11 May 2012 08:40:21 +0100	[thread overview]
Message-ID: <4FACC265.4000408@cam.ac.uk> (raw)
In-Reply-To: <dca0c620c60e1144778bfea74da1336b@mail.gmail.com>

On 5/11/2012 12:53 AM, Ge Gao wrote:
> Dear all,
>
>                  I am building my IIO driver as a module and will
> constantly need to use "insmod" and "rmmod" to install it and remove it
> due to development. However, I found that if I write anything to the
> "trigger/current_trigger", it will not be able to remove it. The error
> code is (11). Even I write "null" to it, it will not be able to be
> removed.
> However, If I don't write anything to it, just insmod and rmmod, it will
> be remove successfully. Any idea what could cause this problem? I followed
> what is in the IIO subsystem driver to write my driver. I can post it if
> anyone want to take a look.
Hi Ge,

I'm afraid I won't be able to do any testing until at least tomorrow.
There are a few things that could give more information though in the
meantime:

* Could you try the above, but note down the reference counts that
lsmod will give you for the various drivers at each step of the
process. (before connecting the trigger, whilst it is connected and upon
disconnecting).

* Is there anything left when you read 'current_trigger' after writing
an invalid name to it?

*  Are you using an existing trigger or is it also part of you driver?

Having the source code when I dig futher into this would also be helpful.

Anyone else seen anything similar?  I haven't run any removal hammering
tests for a month or so, so something might have slipped into the core...

Jonathan
>
>                  Thanks.
>
>
>
> Ge
> --
> To unsubscribe from this list: send the line "unsubscribe linux-iio" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html


  reply	other threads:[~2012-05-11  7:40 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-05-10 23:53 trigger removal problem Ge Gao
2012-05-11  7:40 ` Jonathan Cameron [this message]
2012-05-11 17:45   ` Ge Gao
2012-05-12  8:58     ` Jonathan Cameron
2012-05-14 16:54       ` Ge Gao
2012-05-14 17:30         ` Jonathan Cameron

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=4FACC265.4000408@cam.ac.uk \
    --to=jic23@cam.ac.uk \
    --cc=ggao@invensense.com \
    --cc=linux-iio@vger.kernel.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;
as well as URLs for NNTP newsgroup(s).