[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <AANLkTin+Uvw8=CN+2oawAUHGot8gdM5u98S4zC8QoB=u@mail.gmail.com>
Date: Fri, 25 Mar 2011 18:56:03 -0400
From: Mike Frysinger <vapier@...too.org>
To: Jamie Iles <jamie@...ieiles.com>
Cc: linux-kernel@...r.kernel.org, gregkh@...e.de
Subject: Re: [RFC PATCHv3 3/4] drivers/otp: convert bfin otp to generic OTP
On Fri, Mar 25, 2011 at 13:14, Jamie Iles wrote:
> + /*
> + * Skip the control pages then if we would run into the ECC area skip
> + * past to the next data region.
> + */
> + raw_addr = region_addr + control_words;
> + if (raw_addr > 0x80 * BFIN_OTP_WORDS_PER_PAGE)
> + raw_addr += 0x20 * BFIN_OTP_WORDS_PER_PAGE;
mmm, no, we dont want to do that. the Blackfin documentation is very
exact when it maps out pages, and we want the driver to match the
documentation.
but i guess in the other discussion we had, this would be removed anyways.
> +static int bfin_region_write_word(struct otp_region *region, unsigned long addr,
> + u64 content)
> +{
> + return -EACCES;
> +}
i think we'd just stub this out as NULL and let the common layer take
care of rejecting it ?
> +static const struct otp_device_ops bfin_otp_ops = {
> + .name = "BFIN",
guess this should be "bfin-otp"
> +static const struct otp_region_ops bfin_region_ops = {
> + .read_word = bfin_region_read_word,
> + .write_word = bfin_region_write_word,
> + .get_size = bfin_region_get_size,
> + .get_fmt = bfin_region_get_fmt,
> + .ioctl = bfin_region_ioctl,
> +};
hmm, i just realized this stuff is per-region. wouldnt the
read/write/ioctl make more sense as per-device ?
-mike
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists