All of lore.kernel.org
 help / color / mirror / Atom feed
From: Andrew Jeffery <andrew@aj.id.au>
To: Cyril Bur <cyrilbur@gmail.com>, openbmc@lists.ozlabs.org
Cc: millerjo@linux.vnet.ibm.com
Subject: Re: [PATCH v2 4/5] drivers/mailbox: Add aspeed ast2400/ast2500 mbox driver
Date: Tue, 03 Jan 2017 11:54:21 +1030	[thread overview]
Message-ID: <1483406661.7801.1.camel@aj.id.au> (raw)
In-Reply-To: <1482479795.14044.5.camel@gmail.com>

[-- Attachment #1: Type: text/plain, Size: 1561 bytes --]

On Fri, 2016-12-23 at 18:56 +1100, Cyril Bur wrote:
> On Fri, 2016-12-23 at 13:12 +1030, Andrew Jeffery wrote:
> > On Thu, 2016-12-22 at 17:06 +1100, Cyril Bur wrote:
> > > 
> > > +
> > > +static void mbox_outb(struct mbox *mbox, u8 data, int reg)
> > > +{
> > > +	regmap_write(mbox->regmap, mbox->base + reg, data);
> > 
> > We could use regmap_update_bits() here, but ultimately it's not going
> > to matter. Should we say something if regmap_write() fails (it
> > shouldn't, but if it does that's extra concerning)?
> 
> regmap_update_bits() to about touching the reserved section? Probs a
> good idea.

regmap_update_bits() will just write back what it read for the
untouched bits, which should be 0 in accordance with the datasheet.
It's not really a change in behaviour as we will still be writing to
reserved bits, but I think it makes the intent clear.

> Yeah I thought about putting a dev_err() in there. I'm not opposed, I
> sort of though, we'll you never see them or when you do something
> really bad has happened you'll probably notice everything broke...
> Still in the incredibly unlikely event that a print proves useful I'm
> happy to add it.

I feel an OCD itch to have something there, but I will leave it up to
you.

> > > > +	switch (cmd) {
> > > 
> > > +	case ASPEED_MBOX_IOCTL_ATN:
> > 
> > I think we should rename the IOCTL as what we do below doesn't
> > necessarily raise an interrupt.
> > 
> 
> Agreed, taking unput :). ASPEED_MBOX_IOCTL_WRITE_BYTE ?

That suggestion works for me.

Andrew

[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 801 bytes --]

  reply	other threads:[~2017-01-03  1:24 UTC|newest]

Thread overview: 28+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-12-22  6:06 [PATCH v2 0/5] LPC/MBOX work Cyril Bur
2016-12-22  6:06 ` [PATCH v2 1/5] ARM: dts: aspeed: Reserve BMC ram for host to BMC communication Cyril Bur
2016-12-23  1:01   ` Andrew Jeffery
2016-12-23  7:50     ` Cyril Bur
2016-12-22  6:06 ` [PATCH v2 2/5] ARM: dts: aspeed: Put the lpc_ctrl under lpc_host node for regmap Cyril Bur
2016-12-22  6:06 ` [PATCH v2 3/5] ARM: dts: aspeed: Move mbox under lpc_host node Cyril Bur
2016-12-22  6:06 ` [PATCH v2 4/5] drivers/mailbox: Add aspeed ast2400/ast2500 mbox driver Cyril Bur
2016-12-23  2:42   ` Andrew Jeffery
2016-12-23  7:56     ` Cyril Bur
2017-01-03  1:24       ` Andrew Jeffery [this message]
2017-01-08 21:44         ` Benjamin Herrenschmidt
2017-01-08 23:54           ` Andrew Jeffery
2017-01-08 21:45         ` Benjamin Herrenschmidt
2017-01-09 22:09           ` Cyril Bur
2017-01-09 22:55             ` Andrew Jeffery
2017-01-09 23:18               ` Cyril Bur
2017-01-10  0:07               ` Cyril Bur
2017-01-10  0:10                 ` Andrew Jeffery
2017-01-10  4:28               ` Benjamin Herrenschmidt
2017-01-10  4:36                 ` Cyril Bur
2017-01-10  4:40                   ` Benjamin Herrenschmidt
2017-01-08 21:39   ` Benjamin Herrenschmidt
2016-12-22  6:06 ` [PATCH v2 5/5] drivers/misc: Add aspeed ast2400/ast2500 lpc controlling driver Cyril Bur
2016-12-22 23:54   ` Cyril Bur
2016-12-23  2:43     ` Andrew Jeffery
2016-12-23  2:55   ` Andrew Jeffery
2016-12-23  8:04     ` Cyril Bur
2017-01-03  1:33       ` Andrew Jeffery

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=1483406661.7801.1.camel@aj.id.au \
    --to=andrew@aj.id.au \
    --cc=cyrilbur@gmail.com \
    --cc=millerjo@linux.vnet.ibm.com \
    --cc=openbmc@lists.ozlabs.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.