Skip to content

Commit

Permalink
mtd: Move major number definitions to major.h
Browse files Browse the repository at this point in the history
This patch moves the char and block major number definitions
to major.h to be with the rest of the major numbers.
While doing this, include major.h in the files that need it.

Signed-off-by: Ezequiel Garcia <[email protected]>
Signed-off-by: Brian Norris <[email protected]>
  • Loading branch information
ezequielgarcia authored and computersforpeace committed Nov 7, 2013
1 parent 33094c7 commit f83c383
Show file tree
Hide file tree
Showing 9 changed files with 9 additions and 3 deletions.
1 change: 1 addition & 0 deletions drivers/mtd/devices/block2mtd.c
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
#include <linux/mutex.h>
#include <linux/mount.h>
#include <linux/slab.h>
#include <linux/major.h>

/* Info for the block device */
struct block2mtd_dev {
Expand Down
1 change: 1 addition & 0 deletions drivers/mtd/mtdblock.c
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@
#include <linux/mtd/mtd.h>
#include <linux/mtd/blktrans.h>
#include <linux/mutex.h>
#include <linux/major.h>


struct mtdblk_dev {
Expand Down
1 change: 1 addition & 0 deletions drivers/mtd/mtdblock_ro.c
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
#include <linux/mtd/mtd.h>
#include <linux/mtd/blktrans.h>
#include <linux/module.h>
#include <linux/major.h>

static int mtdblock_readsect(struct mtd_blktrans_dev *dev,
unsigned long block, char *buf)
Expand Down
1 change: 1 addition & 0 deletions drivers/mtd/mtdchar.c
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@
#include <linux/mount.h>
#include <linux/blkpg.h>
#include <linux/magic.h>
#include <linux/major.h>
#include <linux/mtd/mtd.h>
#include <linux/mtd/partitions.h>
#include <linux/mtd/map.h>
Expand Down
1 change: 1 addition & 0 deletions drivers/mtd/mtdcore.c
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@
#include <linux/backing-dev.h>
#include <linux/gfp.h>
#include <linux/slab.h>
#include <linux/major.h>

#include <linux/mtd/mtd.h>
#include <linux/mtd/partitions.h>
Expand Down
1 change: 1 addition & 0 deletions drivers/mtd/mtdsuper.c
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
#include <linux/export.h>
#include <linux/ctype.h>
#include <linux/slab.h>
#include <linux/major.h>

/*
* compare superblocks to see if they're equivalent
Expand Down
1 change: 1 addition & 0 deletions drivers/mtd/ubi/build.c
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@
#include <linux/kthread.h>
#include <linux/kernel.h>
#include <linux/slab.h>
#include <linux/major.h>
#include "ubi.h"

/* Maximum length of the 'mtd=' parameter */
Expand Down
3 changes: 0 additions & 3 deletions include/linux/mtd/mtd.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,6 @@

#include <asm/div64.h>

#define MTD_CHAR_MAJOR 90
#define MTD_BLOCK_MAJOR 31

#define MTD_ERASE_PENDING 0x01
#define MTD_ERASING 0x02
#define MTD_ERASE_SUSPEND 0x04
Expand Down
2 changes: 2 additions & 0 deletions include/uapi/linux/major.h
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@
#define ACSI_MAJOR 28
#define AZTECH_CDROM_MAJOR 29
#define FB_MAJOR 29 /* /dev/fb* framebuffers */
#define MTD_BLOCK_MAJOR 31
#define CM206_CDROM_MAJOR 32
#define IDE2_MAJOR 33
#define IDE3_MAJOR 34
Expand Down Expand Up @@ -105,6 +106,7 @@
#define IDE6_MAJOR 88
#define IDE7_MAJOR 89
#define IDE8_MAJOR 90
#define MTD_CHAR_MAJOR 90
#define IDE9_MAJOR 91

#define DASD_MAJOR 94
Expand Down

0 comments on commit f83c383

Please sign in to comment.