Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit e959c1ce authored by Neeraj Soni's avatar Neeraj Soni
Browse files

block: Expose IOCTL to get partition start sector number



IOCTL added to provide start sector number of requested
partition by client.

Change-Id: I263927e88820d863a4630081cd08afb97acdde62
Signed-off-by: default avatarNeeraj Soni <neersoni@codeaurora.org>
parent 4867091e
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -567,6 +567,8 @@ int blkdev_ioctl(struct block_device *bdev, fmode_t mode, unsigned cmd,
		if ((size >> 9) > ~0UL)
			return -EFBIG;
		return put_ulong(arg, size >> 9);
	case BLKGETSTPART:
		return put_ulong(arg, bdev->bd_part->start_sect);
	case BLKGETSIZE64:
		return put_u64(arg, i_size_read(bdev->bd_inode));
	case BLKTRACESTART:
+1 −0
Original line number Diff line number Diff line
@@ -226,6 +226,7 @@ struct fsxattr {
#define BLKSECDISCARD _IO(0x12,125)
#define BLKROTATIONAL _IO(0x12,126)
#define BLKZEROOUT _IO(0x12,127)
#define BLKGETSTPART _IO(0x12, 128)

#define BMAP_IOCTL 1		/* obsolete - kept for compatibility */
#define FIBMAP	   _IO(0x00,1)	/* bmap access */