Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1159819

Re: [PATCH RFC] hwspinlock: Don't take software spinlock before hwspinlock

Path csiph.com!aioe.org!bofh.it!news.nic.it!robomod
From Ohad Ben-Cohen <ohad@wizery.com>
Newsgroups linux.kernel
Subject Re: [PATCH RFC] hwspinlock: Don't take software spinlock before hwspinlock
Date Sat, 06 Jun 2015 05:30:02 +0200
Message-ID <pycY2-4os-1@gated-at.bofh.it> (permalink)
References <plmBR-1xJ-31@gated-at.bofh.it> <po9f4-5xa-9@gated-at.bofh.it> <poXbQ-3ze-23@gated-at.bofh.it> <pqGgx-2SQ-15@gated-at.bofh.it> <pruQ2-1PV-15@gated-at.bofh.it> <ptcci-7se-3@gated-at.bofh.it> <putNM-6Kl-9@gated-at.bofh.it> <pxOsG-1zh-5@gated-at.bofh.it> <py9GO-7Mb-3@gated-at.bofh.it>
X-Original-To Jeffrey Hugo <jhugo@codeaurora.org>
X-Google-Dkim-Signature v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc:content-type; bh=55qcxGUoX4Lotq9X4ylDI65jUxTEPqgt2EXyvhqo2wE=; b=WzljnTmB2a1rTe/UmsAFVrO0aGgnSP22qgsbqOcnM2y3cw/YBXznxrBulb59taWdgk 4xhoRfYUfEqsj9HDz8LgguSS0KwHRf7pys8xGKMFJMAJjaxEI5c1mrgpIbuuyakOuSeJ pyy/xyaKGNF7Lk5PVlEU2b/N9Z7oswMLrJkdBv9vEQOiOWHyOq3/Z7a38POQh2LAt+sI ifVgVcTpOlfBZjDNE5zre7wtx8PlNVn7cVUsZR7NPtDFIbzzzli7cgRMY6oMP1LJMXDH fAg4dJ9SzTck0cRhOKZ7D7hz87/5WTBYRgmkBHEwxc54TpIkAqV8TEZdsh7rbaRLxR2x YAUA==
X-Gm-Message-State ALoCoQnx2kNtXQME7wb7qa2K5ughC3u+JNV59fYyd9bskMMj43vyQoq8ubNKhxxre3z0x0dFdXRY
X-Received by 10.43.134.1 with SMTP id ia1mr13246554icc.75.1433561348619; Fri, 05 Jun 2015 20:29:08 -0700 (PDT)
MIME-Version 1.0
X-Originating-IP [109.186.38.88]
Content-Type text/plain; charset=UTF-8
Sender robomod@news.nic.it
List-ID <linux-kernel.vger.kernel.org>
X-Mailing-List linux-kernel@vger.kernel.org
Approved robomod@news.nic.it
Lines 27
Organization linux.* mail to news gateway
X-Original-Cc Lina Iyer <lina.iyer@linaro.org>, "Anna, Suman" <s-anna@ti.com>, Bjorn Andersson <Bjorn.Andersson@sonymobile.com>, Andy Gross <agross@codeaurora.org>, "linux-arm-msm@vger.kernel.org" <linux-arm-msm@vger.kernel.org>, "linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>, Kumar Gala <galak@codeaurora.org>
X-Original-Date Sat, 6 Jun 2015 06:28:48 +0300
X-Original-Message-ID <CAK=WgbYSev_y45Gh3oJ+1xNPdvvRy=gpa=iSTgPydNodPeh3sQ@mail.gmail.com>
X-Original-References <1430500026-47990-1-git-send-email-lina.iyer@linaro.org> <CAK=WgbYK24aTSmoSZGXDRq2GOBn6296Xa3zPZP0ycNGOtfHRxg@mail.gmail.com> <20150511144608.GB16124@linaro.org> <CAK=Wgbae_zXhzt9fL=YD6J9eeA8Xcgut_pBm52DNC5BE2kWCVg@mail.gmail.com> <20150518150302.GA23206@linaro.org> <CAK=Wgba0BVZLTJb7SYTX_NJhd46DkW-w8uHSyWsRg=xqK7jArw@mail.gmail.com> <20150526203634.GL23206@linaro.org> <CAK=WgbbX5dZ7=WzMr3xGVVP1vBPj_aboLnPOZZsHGi+o-Y2_Cg@mail.gmail.com> <557235C1.3020001@codeaurora.org>
X-Original-Sender linux-kernel-owner@vger.kernel.org
Xref aioe.org linux.kernel:1159819

Show key headers only | View raw


On Sat, Jun 6, 2015 at 2:50 AM, Jeffrey Hugo <jhugo@codeaurora.org> wrote:
> If you still wish to scope out a capability based alternative, would you
> please provide some details about how you envision it working?  An example
> of the API, how it would be used, future usecases that might be covered by
> it, etc.  That would give us specifics we can discuss and weigh the merits
> of.

How about:
- add a 'hwcaps' member to hwspinlock_device, and define single cap
called HWL_CAP_ALLOW_RAW
- add new 'hwcaps' parameter to hwspin_lock_register
- omap_hwspinlock.c will pass NULL, qcom_hwspinlock will pass HWL_CAP_ALLOW_RAW
- hwspin_lock_register will set hwcaps accordingly
- before a lock is taken in RAW mode, the capabilities are checked
- document everything nicely

Unless I'm missing something, it should take 5 minutes or less. For
reference, feel free to check out mmc_host's caps member and its
usage.

Thanks,
Ohad.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Back to linux.kernel | Previous | Next — Previous in thread | Find similar | Unroll thread


Thread

Re: [PATCH RFC] hwspinlock: Don't take software spinlock before hwspinlock Jeffrey Hugo <jhugo@codeaurora.org> - 2015-06-06 02:00 +0200
  Re: [PATCH RFC] hwspinlock: Don't take software spinlock before hwspinlock Ohad Ben-Cohen <ohad@wizery.com> - 2015-06-06 05:30 +0200

csiph-web