public inbox for linux-media@vger.kernel.org
 help / color / mirror / Atom feed
From: Alexander Strakh <strakh@ispras.ru>
To: Vladimir Shebordaev <vshebordaev@mail.ru>,
	Mauro Carvalho Chehab <mchehab@infradead.org>,
	linux-media@vger.kernel.org,
	Linux Kernlel Mailing List <linux-kernel@vger.kernel.org>
Subject: [BUG] radio-gemtek-pci.c: double mutex_lock
Date: Thu, 8 Oct 2009 18:52:50 +0000	[thread overview]
Message-ID: <200910081852.50816.strakh@ispras.ru> (raw)

	KERNEL_VERSION: 2.6.31
	DESCRIBE:
In driver ./drivers/media/radio/radio-gemtek-pci.c 
mutex_lock is called first time in line 184, then in line 186 
gemtek_pci_setfrequency is called.

182 static void gemtek_pci_unmute(struct gemtek_pci *card)
183 {
184		mutex_lock(&card->lock);
185		if (card->mute) {
186         	gemtek_pci_setfrequency(card, card->current_frequency);
187			card->mute = false;
188		}
189		mutex_unlock(&card->lock);190 }

In gemtek_pci_setfrequency we call mutex_lock again in line 152

144 static void gemtek_pci_setfrequency(struct gemtek_pci *card, unsigned long 
frequency)
145 {
146         int i;
147         u32 value = frequency / 200 + 856;
148         u16 mask = 0x8000;
149         u8 last_byte;
150         u32 port = card->iobase;
151
152         mutex_lock(&card->lock);

Found by : Linux Driver Verification project

             reply	other threads:[~2009-10-08 14:50 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-10-08 18:52 Alexander Strakh [this message]
2009-10-08 18:47 ` [BUG] radio-gemtek-pci.c: double mutex_lock Jiri Kosina
2009-11-05 16:27   ` Hans Verkuil

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=200910081852.50816.strakh@ispras.ru \
    --to=strakh@ispras.ru \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-media@vger.kernel.org \
    --cc=mchehab@infradead.org \
    --cc=vshebordaev@mail.ru \
    /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