mbox series

[v2,0/5] unconfuse get_unmapped_area and point/unpoint driver methods

Message ID 20171017152826.11658-1-nicolas.pitre@linaro.org
Headers show
Series unconfuse get_unmapped_area and point/unpoint driver methods | expand

Message

Nicolas Pitre Oct. 17, 2017, 3:28 p.m. UTC
This series improves or implements the point and unpoint driver methods
and reimplements mtd_get_unmapped_area() in terms of those. Because
mtd->_point() provides a superset of what mtd->_get_unmapped_area() does
then there is no reason for having both. Or worse: having one but not
the other.

This is motivated by my work on XIP cramfs for both MMU and !MMU systems
where I do need the more complete point functionality. And it just looks
like the right thing to do.

This is also available on top of Linux v4.14-rc3 via git here:

  http://git.linaro.org/people/nicolas.pitre/linux mtd_point


Changes from v1:

- Fix retlen computation in mtdram.c:ram_point().

- Added Richard Weinberger's REviewd-by tags.


diffstat:

 drivers/mtd/chips/map_ram.c  | 34 ++++++++++++++++++++--------------
 drivers/mtd/chips/map_rom.c  | 34 +++++++++++++++++++++-------------
 drivers/mtd/devices/mtdram.c | 36 ++++++++++++++++++++++--------------
 drivers/mtd/mtdconcat.c      | 27 ---------------------------
 drivers/mtd/mtdcore.c        | 17 ++++++++++++-----
 drivers/mtd/mtdpart.c        | 14 --------------
 include/linux/mtd/mtd.h      |  4 ----
 7 files changed, 75 insertions(+), 91 deletions(-)

______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/

Comments

Nicolas Pitre Oct. 24, 2017, 5:22 p.m. UTC | #1
Ping.

On Tue, 17 Oct 2017, Nicolas Pitre wrote:

> This series improves or implements the point and unpoint driver methods

> and reimplements mtd_get_unmapped_area() in terms of those. Because

> mtd->_point() provides a superset of what mtd->_get_unmapped_area() does

> then there is no reason for having both. Or worse: having one but not

> the other.

> 

> This is motivated by my work on XIP cramfs for both MMU and !MMU systems

> where I do need the more complete point functionality. And it just looks

> like the right thing to do.

> 

> This is also available on top of Linux v4.14-rc3 via git here:

> 

>   http://git.linaro.org/people/nicolas.pitre/linux mtd_point

> 

> 

> Changes from v1:

> 

> - Fix retlen computation in mtdram.c:ram_point().

> 

> - Added Richard Weinberger's REviewd-by tags.

> 

> 

> diffstat:

> 

>  drivers/mtd/chips/map_ram.c  | 34 ++++++++++++++++++++--------------

>  drivers/mtd/chips/map_rom.c  | 34 +++++++++++++++++++++-------------

>  drivers/mtd/devices/mtdram.c | 36 ++++++++++++++++++++++--------------

>  drivers/mtd/mtdconcat.c      | 27 ---------------------------

>  drivers/mtd/mtdcore.c        | 17 ++++++++++++-----

>  drivers/mtd/mtdpart.c        | 14 --------------

>  include/linux/mtd/mtd.h      |  4 ----

>  7 files changed, 75 insertions(+), 91 deletions(-)

> 

> ______________________________________________________

> Linux MTD discussion mailing list

> http://lists.infradead.org/mailman/listinfo/linux-mtd/

> 


______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/
Richard Weinberger Oct. 25, 2017, 12:24 p.m. UTC | #2
On Tue, Oct 24, 2017 at 7:22 PM, Nicolas Pitre <nicolas.pitre@linaro.org> wrote:
>

> Ping.


I'm currently at ELCE and not really active.
But your patches are not in /dev/null. :-)

-- 
Thanks,
//richard

______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/
Nicolas Pitre Oct. 25, 2017, 3:36 p.m. UTC | #3
On Wed, 25 Oct 2017, Richard Weinberger wrote:

> On Tue, Oct 24, 2017 at 7:22 PM, Nicolas Pitre <nicolas.pitre@linaro.org> wrote:

> >

> > Ping.

> 

> I'm currently at ELCE and not really active.

> But your patches are not in /dev/null. :-)


OK, thanks for confirming.  I just want to not miss the next merge 
window as some other patches already queued for mainline rely on those 
MTD patches to work properly.


Nicolas

______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/
Boris Brezillon Oct. 27, 2017, 12:06 p.m. UTC | #4
Hi Nicolas,

Some of your commits do not have commit messages (just a subject and
that's all). I know you're an experimented kernel developer and you
might find this superfluous, but we try to push all MTD contributors to
write a commit message, even if it's just a one line description that
basically repeats what the subject line says. Would you mind adding a
short description to patch 2 and 3.

Other than that, the changes look good to me, so

Acked-by: Boris Brezillon <boris.brezillon@free-electrons.com>


On Tue, 17 Oct 2017 11:28:21 -0400
Nicolas Pitre <nicolas.pitre@linaro.org> wrote:

> This series improves or implements the point and unpoint driver methods

> and reimplements mtd_get_unmapped_area() in terms of those. Because

> mtd->_point() provides a superset of what mtd->_get_unmapped_area() does

> then there is no reason for having both. Or worse: having one but not

> the other.

> 

> This is motivated by my work on XIP cramfs for both MMU and !MMU systems

> where I do need the more complete point functionality. And it just looks

> like the right thing to do.

> 

> This is also available on top of Linux v4.14-rc3 via git here:

> 

>   http://git.linaro.org/people/nicolas.pitre/linux mtd_point

> 

> 

> Changes from v1:

> 

> - Fix retlen computation in mtdram.c:ram_point().

> 

> - Added Richard Weinberger's REviewd-by tags.

> 

> 

> diffstat:

> 

>  drivers/mtd/chips/map_ram.c  | 34 ++++++++++++++++++++--------------

>  drivers/mtd/chips/map_rom.c  | 34 +++++++++++++++++++++-------------

>  drivers/mtd/devices/mtdram.c | 36 ++++++++++++++++++++++--------------

>  drivers/mtd/mtdconcat.c      | 27 ---------------------------

>  drivers/mtd/mtdcore.c        | 17 ++++++++++++-----

>  drivers/mtd/mtdpart.c        | 14 --------------

>  include/linux/mtd/mtd.h      |  4 ----

>  7 files changed, 75 insertions(+), 91 deletions(-)

> 

> ______________________________________________________

> Linux MTD discussion mailing list

> http://lists.infradead.org/mailman/listinfo/linux-mtd/



______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/
Nicolas Pitre Oct. 27, 2017, 3:27 p.m. UTC | #5
On Fri, 27 Oct 2017, Boris Brezillon wrote:

> Hi Nicolas,

> 

> Some of your commits do not have commit messages (just a subject and

> that's all). I know you're an experimented kernel developer and you

> might find this superfluous, but we try to push all MTD contributors to

> write a commit message, even if it's just a one line description that

> basically repeats what the subject line says. Would you mind adding a

> short description to patch 2 and 3.

> 

> Other than that, the changes look good to me, so

> 

> Acked-by: Boris Brezillon <boris.brezillon@free-electrons.com>


No problem.

I added a one-liner justification to those commits, and your ACK to the 
series.

This has been pushed here if you wish to pull it:

  http://git.linaro.org/people/nicolas.pitre/linux mtd_point

Or if you prefer that I repost the whole thing just say so and I'll 
oblige.

Thanks.


> On Tue, 17 Oct 2017 11:28:21 -0400

> Nicolas Pitre <nicolas.pitre@linaro.org> wrote:

> 

> > This series improves or implements the point and unpoint driver methods

> > and reimplements mtd_get_unmapped_area() in terms of those. Because

> > mtd->_point() provides a superset of what mtd->_get_unmapped_area() does

> > then there is no reason for having both. Or worse: having one but not

> > the other.

> > 

> > This is motivated by my work on XIP cramfs for both MMU and !MMU systems

> > where I do need the more complete point functionality. And it just looks

> > like the right thing to do.

> > 

> > This is also available on top of Linux v4.14-rc3 via git here:

> > 

> >   http://git.linaro.org/people/nicolas.pitre/linux mtd_point

> > 

> > 

> > Changes from v1:

> > 

> > - Fix retlen computation in mtdram.c:ram_point().

> > 

> > - Added Richard Weinberger's REviewd-by tags.

> > 

> > 

> > diffstat:

> > 

> >  drivers/mtd/chips/map_ram.c  | 34 ++++++++++++++++++++--------------

> >  drivers/mtd/chips/map_rom.c  | 34 +++++++++++++++++++++-------------

> >  drivers/mtd/devices/mtdram.c | 36 ++++++++++++++++++++++--------------

> >  drivers/mtd/mtdconcat.c      | 27 ---------------------------

> >  drivers/mtd/mtdcore.c        | 17 ++++++++++++-----

> >  drivers/mtd/mtdpart.c        | 14 --------------

> >  include/linux/mtd/mtd.h      |  4 ----

> >  7 files changed, 75 insertions(+), 91 deletions(-)

> > 

> > ______________________________________________________

> > Linux MTD discussion mailing list

> > http://lists.infradead.org/mailman/listinfo/linux-mtd/

> 

> 


______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/
Boris Brezillon Oct. 30, 2017, 8:58 a.m. UTC | #6
Hi Nicolas,

On Fri, 27 Oct 2017 11:27:46 -0400 (EDT)
Nicolas Pitre <nicolas.pitre@linaro.org> wrote:

> On Fri, 27 Oct 2017, Boris Brezillon wrote:

> 

> > Hi Nicolas,

> > 

> > Some of your commits do not have commit messages (just a subject and

> > that's all). I know you're an experimented kernel developer and you

> > might find this superfluous, but we try to push all MTD contributors to

> > write a commit message, even if it's just a one line description that

> > basically repeats what the subject line says. Would you mind adding a

> > short description to patch 2 and 3.

> > 

> > Other than that, the changes look good to me, so

> > 

> > Acked-by: Boris Brezillon <boris.brezillon@free-electrons.com>  

> 

> No problem.

> 

> I added a one-liner justification to those commits, and your ACK to the 

> series.

> 

> This has been pushed here if you wish to pull it:

> 

>   http://git.linaro.org/people/nicolas.pitre/linux mtd_point

> 

> Or if you prefer that I repost the whole thing just say so and I'll 

> oblige.


It's easier for us if you repost the whole series (we use patchwork to
track MTD patches, and I like to have the version that hits mainline
available on patchwork too).

Thanks,

Boris

______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/
Chris Brandt Oct. 30, 2017, 6:12 p.m. UTC | #7
On Tuesday, October 17, 2017 1, Nicolas Pitre wrote:
> This series improves or implements the point and unpoint driver methods

> and reimplements mtd_get_unmapped_area() in terms of those. Because

> mtd->_point() provides a superset of what mtd->_get_unmapped_area() does

> then there is no reason for having both. Or worse: having one but not

> the other.

> 

> This is motivated by my work on XIP cramfs for both MMU and !MMU systems

> where I do need the more complete point functionality. And it just looks

> like the right thing to do.

> 

> This is also available on top of Linux v4.14-rc3 via git here:

> 

>   http://git.linaro.org/people/nicolas.pitre/linux mtd_point

> 

> 

> Changes from v1:

> 

> - Fix retlen computation in mtdram.c:ram_point().

> 

> - Added Richard Weinberger's REviewd-by tags.

> 

> 

> diffstat:

> 

>  drivers/mtd/chips/map_ram.c  | 34 ++++++++++++++++++++--------------

>  drivers/mtd/chips/map_rom.c  | 34 +++++++++++++++++++++-------------

>  drivers/mtd/devices/mtdram.c | 36 ++++++++++++++++++++++--------------

>  drivers/mtd/mtdconcat.c      | 27 ---------------------------

>  drivers/mtd/mtdcore.c        | 17 ++++++++++++-----

>  drivers/mtd/mtdpart.c        | 14 --------------

>  include/linux/mtd/mtd.h      |  4 ----

>  7 files changed, 75 insertions(+), 91 deletions(-)


I was able to boot my system with the following kernel options:

  "rootfstype=cramfs root=mtd:rootfs_xipcramfs"

This meant the cramfs image was one where the executable code pages 
remained in flash.


Therefore, for this MTD series, applied on top of the file system series 
"[PATCH v6 0/4] cramfs refresh for embedded usage":

Tested-by: Chris Brandt <chris.brandt@renesas.com>



______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/
Nicolas Pitre Oct. 30, 2017, 6:34 p.m. UTC | #8
On Mon, 30 Oct 2017, Chris Brandt wrote:

> I was able to boot my system with the following kernel options:

> 

>   "rootfstype=cramfs root=mtd:rootfs_xipcramfs"

> 

> This meant the cramfs image was one where the executable code pages 

> remained in flash.

> 

> 

> Therefore, for this MTD series, applied on top of the file system series 

> "[PATCH v6 0/4] cramfs refresh for embedded usage":

> 

> Tested-by: Chris Brandt <chris.brandt@renesas.com>


Thanks for testing!


Nicolas

______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/
Chris Brandt Oct. 30, 2017, 6:41 p.m. UTC | #9
On Monday, October 30, 2017, Nicolas Pitre wrote:
> On Mon, 30 Oct 2017, Chris Brandt wrote:

> 

> > I was able to boot my system with the following kernel options:

> >

> >   "rootfstype=cramfs root=mtd:rootfs_xipcramfs"

> >

> > This meant the cramfs image was one where the executable code pages

> > remained in flash.

> >

> >

> > Therefore, for this MTD series, applied on top of the file system series

> > "[PATCH v6 0/4] cramfs refresh for embedded usage":

> >

> > Tested-by: Chris Brandt <chris.brandt@renesas.com>

> 

> Thanks for testing!

> 

> 

> Nicolas



Thank you for implementing!


I've been trying to keep AXFS up to date with recent kernels since it 
was my only solution for an XIP file system, but now that we'll have an 
in-kernel solution, it's not as critical anymore if/when AXFS breaks 
again.


Chris


______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/
Nicolas Pitre Nov. 3, 2017, 3:19 a.m. UTC | #10
On Mon, 30 Oct 2017, Boris Brezillon wrote:

> Hi Nicolas,

> 

> On Fri, 27 Oct 2017 11:27:46 -0400 (EDT)

> Nicolas Pitre <nicolas.pitre@linaro.org> wrote:

> 

> > On Fri, 27 Oct 2017, Boris Brezillon wrote:

> > 

> > > Hi Nicolas,

> > > 

> > > Some of your commits do not have commit messages (just a subject and

> > > that's all). I know you're an experimented kernel developer and you

> > > might find this superfluous, but we try to push all MTD contributors to

> > > write a commit message, even if it's just a one line description that

> > > basically repeats what the subject line says. Would you mind adding a

> > > short description to patch 2 and 3.

> > > 

> > > Other than that, the changes look good to me, so

> > > 

> > > Acked-by: Boris Brezillon <boris.brezillon@free-electrons.com>  

> > 

> > No problem.

> > 

> > I added a one-liner justification to those commits, and your ACK to the 

> > series.

> > 

> > This has been pushed here if you wish to pull it:

> > 

> >   http://git.linaro.org/people/nicolas.pitre/linux mtd_point

> > 

> > Or if you prefer that I repost the whole thing just say so and I'll 

> > oblige.

> 

> It's easier for us if you repost the whole series (we use patchwork to

> track MTD patches, and I like to have the version that hits mainline

> available on patchwork too).


V3 were posted earlier this week. With the looming merge window I just 
want to confirm everything is fine on your side.

Thanks.


Nicolas

______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/