linux-modules.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Rusty Russell <rusty@rustcorp.com.au>
To: Lucas De Marchi <lucas.de.marchi@gmail.com>,
	lkml <linux-kernel@vger.kernel.org>,
	linux-modules <linux-modules@vger.kernel.org>
Cc: "Kent Overstreet" <koverstreet@google.com>
Cc: Rafael J. Wysocki <rjw@sisk.pl>
Cc: Viresh Kumar <viresh.kumar@linaro.org>
Cc: cpufreq@vger.kernel.org
Cc: linux-pm@vger.kernel.org
Subject: Re: module refcnt underflow
Date: Mon, 01 Jul 2013 12:08:36 +0930	[thread overview]
Message-ID: <8738rzt36b.fsf@rustcorp.com.au> (raw)
In-Reply-To: <CAKi4VA+RBToB3fO21N-QWdPZeqGpg1ASHzn3vwB9t64ApdwrsA@mail.gmail.com>

Lucas De Marchi <lucas.de.marchi@gmail.com> writes:
> Hi,
>
> While checking somethings for a next release of kmod I noticed this
> strange thing:
>
> cat /sys/module/acpi_cpufreq/refcnt
> 18446744073709551614
>
> We outputs this as "-1" in lsmod because we treat the value as signed.
> I was just going to change it to unsigned to make it compatible with
> what module-init-tools does but... For me it looks like a bug in the
> kernel since in this file we just have the output of
> kernel/module.c:module_refcount()
>
> I have this behavior on 3.9.2 but judging by the missing commits in
> kernel/module.c, this would also happen in latest head. I've never
> seen such a value so I guess it might be difficult to reproduce it
> again.
>
> Any hints on what could cause decs to be greater than incs in module_refcount()?

That points to a bug in the cpufreq code.

At a glance, there's nothing obvious, but there are quite a few
reference counts in that code.

Informed people cc'd...

Thanks,
Rusty.

      reply	other threads:[~2013-07-01  2:38 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-06-26 16:20 module refcnt underflow Lucas De Marchi
2013-07-01  2:38 ` Rusty Russell [this message]

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=8738rzt36b.fsf@rustcorp.com.au \
    --to=rusty@rustcorp.com.au \
    --cc=koverstreet@google.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-modules@vger.kernel.org \
    --cc=lucas.de.marchi@gmail.com \
    /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).