public inbox for linux-next@vger.kernel.org 
 help / color / mirror / Atom feed
* linux-next: manual merge of the block tree with the l2-mtd tree
@ 2015-01-21  3:18 Stephen Rothwell
  0 siblings, 0 replies; 2+ messages in thread
From: Stephen Rothwell @ 2015-01-21  3:18 UTC (permalink / raw)
  To: Jens Axboe, Brian Norris; +Cc: linux-next, linux-kernel, Christoph Hellwig

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

Hi Jens,

Today's linux-next merge of the block tree got a conflict in
drivers/mtd/mtdcore.c between commit 3efe41be224c ("mtd: implement
common reboot notifier boilerplate") from the  tree and commit
b4caecd48005 ("fs: introduce f_op->mmap_capabilities for nommu mmap
support") from the block tree.

I fixed it up (see below) and can carry the fix as necessary (no action
is required).

-- 
Cheers,
Stephen Rothwell                    sfr@canb•auug.org.au

diff --cc drivers/mtd/mtdcore.c
index cbc0fc46d2d6,ff38a1df22f7..000000000000
--- a/drivers/mtd/mtdcore.c
+++ b/drivers/mtd/mtdcore.c
@@@ -366,17 -339,22 +340,33 @@@ static struct device_type mtd_devtype 
  	.release	= mtd_release,
  };
  
 +static int mtd_reboot_notifier(struct notifier_block *n, unsigned long state,
 +			       void *cmd)
 +{
 +	struct mtd_info *mtd;
 +
 +	mtd = container_of(n, struct mtd_info, reboot_notifier);
 +	mtd->_reboot(mtd);
 +
 +	return NOTIFY_DONE;
 +}
 +
+ #ifndef CONFIG_MMU
+ unsigned mtd_mmap_capabilities(struct mtd_info *mtd)
+ {
+ 	switch (mtd->type) {
+ 	case MTD_RAM:
+ 		return NOMMU_MAP_COPY | NOMMU_MAP_DIRECT | NOMMU_MAP_EXEC |
+ 			NOMMU_MAP_READ | NOMMU_MAP_WRITE;
+ 	case MTD_ROM:
+ 		return NOMMU_MAP_COPY | NOMMU_MAP_DIRECT | NOMMU_MAP_EXEC |
+ 			NOMMU_MAP_READ;
+ 	default:
+ 		return NOMMU_MAP_COPY;
+ 	}
+ }
+ #endif
+ 
  /**
   *	add_mtd_device - register an MTD device
   *	@mtd: pointer to new MTD device info structure

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 819 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

* linux-next: manual merge of the block tree with the l2-mtd tree
@ 2015-01-29  3:04 Stephen Rothwell
  0 siblings, 0 replies; 2+ messages in thread
From: Stephen Rothwell @ 2015-01-29  3:04 UTC (permalink / raw)
  To: Jens Axboe, Brian Norris; +Cc: linux-next, linux-kernel, Christoph Hellwig

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

Hi Jens,

Today's linux-next merge of the block tree got a conflict in
drivers/mtd/mtdcore.c between commit 3efe41be224c ("mtd: implement
common reboot notifier boilerplate") from the  tree and commit
b4caecd48005 ("fs: introduce f_op->mmap_capabilities for nommu mmap
support") from the block tree.

I fixed it up (see below) and can carry the fix as necessary (no action
is required).

-- 
Cheers,
Stephen Rothwell                    sfr@canb•auug.org.au

diff --cc drivers/mtd/mtdcore.c
index cbc0fc46d2d6,0ec4d6ea1e4b..000000000000
--- a/drivers/mtd/mtdcore.c
+++ b/drivers/mtd/mtdcore.c
@@@ -366,17 -339,23 +340,34 @@@ static struct device_type mtd_devtype 
  	.release	= mtd_release,
  };
  
 +static int mtd_reboot_notifier(struct notifier_block *n, unsigned long state,
 +			       void *cmd)
 +{
 +	struct mtd_info *mtd;
 +
 +	mtd = container_of(n, struct mtd_info, reboot_notifier);
 +	mtd->_reboot(mtd);
 +
 +	return NOTIFY_DONE;
 +}
 +
+ #ifndef CONFIG_MMU
+ unsigned mtd_mmap_capabilities(struct mtd_info *mtd)
+ {
+ 	switch (mtd->type) {
+ 	case MTD_RAM:
+ 		return NOMMU_MAP_COPY | NOMMU_MAP_DIRECT | NOMMU_MAP_EXEC |
+ 			NOMMU_MAP_READ | NOMMU_MAP_WRITE;
+ 	case MTD_ROM:
+ 		return NOMMU_MAP_COPY | NOMMU_MAP_DIRECT | NOMMU_MAP_EXEC |
+ 			NOMMU_MAP_READ;
+ 	default:
+ 		return NOMMU_MAP_COPY;
+ 	}
+ }
+ EXPORT_SYMBOL_GPL(mtd_mmap_capabilities);
+ #endif
+ 
  /**
   *	add_mtd_device - register an MTD device
   *	@mtd: pointer to new MTD device info structure

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 819 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2015-01-29  3:04 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-01-21  3:18 linux-next: manual merge of the block tree with the l2-mtd tree Stephen Rothwell
  -- strict thread matches above, loose matches on Subject: below --
2015-01-29  3:04 Stephen Rothwell

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox