From: Gilad Avidov <gavidov@codeaurora.org>
To: "Ivan T. Ivanov" <iivanov@mm-sol.com>
Cc: sdharia@codeaurora.org, mlocke@codeaurora.org,
linux-arm-msm@vger.kernel.org, gregkh@linuxfoundation.org,
linux-kernel@vger.kernel.org, galak@codeaurora.org,
agross@codeaurora.org
Subject: Re: [PATCH V4 2/2] spmi: pmic_arb: add support for hw version 2
Date: Wed, 11 Mar 2015 16:55:59 -0600 [thread overview]
Message-ID: <20150311165559.29d6cfe4@gavidov-lnx.qualcomm.com> (raw)
In-Reply-To: <1424707570.2340.9.camel@mm-sol.com>
Hi Ivan,
On Mon, 23 Feb 2015 18:06:10 +0200
"Ivan T. Ivanov" <iivanov@mm-sol.com> wrote:
>
> Hi Gilad,
>
> On Thu, 2015-02-19 at 15:54 -0700, Gilad Avidov wrote:
>
> >
> > +
> > +static u32 pmic_arb_fmt_cmd_v1(u8 opc, u8 sid, u16 addr, u8 bc)
> > +{
> > + return (opc << 27) | ((sid & 0xf) << 20) | (addr << 4) |
> > (bc & 0x7); +}
> > +
> > +static u32 pmic_arb_fmt_cmd_v2(u8 opc, u8 sid, u16 addr, u8 bc)
> > +{
> > + return (opc << 27) | ((addr & 0xff) << 4) | (bc & 0x7);
>
> This one is looking suspicious. Address could be only 8 bits? Slave
> ID is not used?
>
> Is this correct?
Yes it is correct.
On HW v2 we are writing the command directly to a channel which is
specific (already configured) to an SID and the upper 8 bits of the
address.
This is how we get the channel:
u32 offset = pmic_arb->ver_ops->offset(pmic_arb, sid, addr);
The lower 8 bits of the address is all that we need to have the
entire 20bits of SPMI addressing.
Thanks,
Gilad
>
> Ivan
> --
> To unsubscribe from this list: send the line "unsubscribe
> linux-arm-msm" in the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
next prev parent reply other threads:[~2015-03-11 22:56 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-02-19 22:54 [PATCH V4 0/2] [PATCH V4 0/2] add support for pmic_arb v2 and correct framework Gilad Avidov
2015-02-19 22:54 ` [PATCH V4 1/2] spmi: remove wakeup command before slave probe Gilad Avidov
2015-02-19 22:54 ` [PATCH V4 2/2] spmi: pmic_arb: add support for hw version 2 Gilad Avidov
2015-02-23 9:59 ` Ivan T. Ivanov
2015-03-10 10:51 ` Ivan T. Ivanov
2015-03-11 23:43 ` Gilad Avidov
2015-02-23 16:06 ` Ivan T. Ivanov
2015-03-11 22:55 ` Gilad Avidov [this message]
2015-02-24 11:01 ` Ivan T. Ivanov
2015-03-11 19:05 ` Gilad Avidov
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=20150311165559.29d6cfe4@gavidov-lnx.qualcomm.com \
--to=gavidov@codeaurora.org \
--cc=agross@codeaurora.org \
--cc=galak@codeaurora.org \
--cc=gregkh@linuxfoundation.org \
--cc=iivanov@mm-sol.com \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mlocke@codeaurora.org \
--cc=sdharia@codeaurora.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
all inboxes | Powered by JetHome®