From: David Miller <davem@davemloft.net>
To: sjur.brandeland@stericsson.com
Cc: linux@arm.linux.org.uk, sjurbr@gmail.com, netdev@vger.kernel.org,
linux-arm-kernel@lists.infradead.org,
linus.walleij@stericsson.com, stefan.xk.nilsson@stericsson.com,
amarnath.bangalore.revanna@stericsson.com
Subject: Re: [PATCH 2/4] caif-u5500: CAIF shared memory transport protocol
Date: Wed, 27 Oct 2010 11:07:32 -0700 (PDT) [thread overview]
Message-ID: <20101027.110732.48492064.davem@davemloft.net> (raw)
In-Reply-To: <1287774235-11151-3-git-send-email-sjur.brandeland@stericsson.com>
From: Sjur Braendeland <sjur.brandeland@stericsson.com>
Date: Fri, 22 Oct 2010 21:03:53 +0200
> + if (!in_irq())
> + spin_lock_bh(&pshm_drv->lock);
> + else
> + spin_lock_irqsave(&pshm_drv->lock, flags);
You should never have contextual based locking schemes like this,
it's not just ugly it's also deadlock prone.
next prev parent reply other threads:[~2010-10-27 18:07 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-10-22 19:03 [PATCH 0/4] caif-u5500: CAIF shared memory/mailbox driver Sjur Braendeland
2010-10-22 19:03 ` [PATCH 1/4] caif-u5500: Adding shared memory include Sjur Braendeland
2010-10-22 19:03 ` [PATCH 2/4] caif-u5500: CAIF shared memory transport protocol Sjur Braendeland
2010-10-22 19:03 ` [PATCH 3/4] caif-u5500: CAIF shared memory mailbox interface Sjur Braendeland
2010-10-22 19:03 ` [PATCH 4/4] caif-u5500: Build config for CAIF shared mem driver Sjur Braendeland
2010-10-27 18:07 ` David Miller [this message]
2010-10-27 18:34 ` [PATCHv2 1/4] caif-u5500: Adding shared memory include Sjur Braendeland
2010-10-27 18:34 ` [PATCHv2 2/4] caif-u5500: CAIF shared memory transport protocol Sjur Braendeland
2010-10-27 18:34 ` [PATCHv2 3/4] caif-u5500: CAIF shared memory mailbox interface Sjur Braendeland
2010-10-27 18:34 ` [PATCHv2 4/4] caif-u5500: Build config for CAIF shared mem driver Sjur Braendeland
2010-10-27 19:31 ` David Miller
2010-10-27 19:31 ` [PATCHv2 3/4] caif-u5500: CAIF shared memory mailbox interface David Miller
2010-10-27 19:31 ` [PATCHv2 2/4] caif-u5500: CAIF shared memory transport protocol David Miller
2010-10-27 19:31 ` [PATCHv2 1/4] caif-u5500: Adding shared memory include David Miller
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=20101027.110732.48492064.davem@davemloft.net \
--to=davem@davemloft.net \
--cc=amarnath.bangalore.revanna@stericsson.com \
--cc=linus.walleij@stericsson.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux@arm.linux.org.uk \
--cc=netdev@vger.kernel.org \
--cc=sjur.brandeland@stericsson.com \
--cc=sjurbr@gmail.com \
--cc=stefan.xk.nilsson@stericsson.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).