Merge tag 'for-5.5/block-20191121' of git://git.kernel.dk/linux-block
Pull core block updates from Jens Axboe: "Due to more granular branches, this one is small and will be followed with other core branches that add specific features. I meant to just have a core and drivers branch, but external dependencies we ended up adding a few more that are also core. The changes are: - Fixes and improvements for the zoned device support (Ajay, Damien) - sed-opal table writing and datastore UID (Revanth) - blk-cgroup (and bfq) blk-cgroup stat fixes (Tejun) - Improvements to the block stats tracking (Pavel) - Fix for overruning sysfs buffer for large number of CPUs (Ming) - Optimization for small IO (Ming, Christoph) - Fix typo in RWH lifetime hint (Eugene) - Dead code removal and documentation (Bart) - Reduction in memory usage for queue and tag set (Bart) - Kerneldoc header documentation (André) - Device/partition revalidation fixes (Jan) - Stats tracking for flush requests (Konstantin) - Various other little fixes here and there (et al)" * tag 'for-5.5/block-20191121' of git://git.kernel.dk/linux-block: (48 commits) Revert "block: split bio if the only bvec's length is > SZ_4K" block: add iostat counters for flush requests block,bfq: Skip tracing hooks if possible block: sed-opal: Introduce SUM_SET_LIST parameter and append it using 'add_token_u64' blk-cgroup: cgroup_rstat_updated() shouldn't be called on cgroup1 block: Don't disable interrupts in trigger_softirq() sbitmap: Delete sbitmap_any_bit_clear() blk-mq: Delete blk_mq_has_free_tags() and blk_mq_can_queue() block: split bio if the only bvec's length is > SZ_4K block: still try to split bio if the bvec crosses pages blk-cgroup: separate out blkg_rwstat under CONFIG_BLK_CGROUP_RWSTAT blk-cgroup: reimplement basic IO stats using cgroup rstat blk-cgroup: remove now unused blkg_print_stat_{bytes|ios}_recursive() blk-throtl: stop using blkg->stat_bytes and ->stat_ios bfq-iosched: stop using blkg->stat_bytes and ->stat_ios bfq-iosched: relocate bfqg_*rwstat*() helpers block: add zone open, close and finish ioctl support block: add zone open, close and finish operations block: Simplify REQ_OP_ZONE_RESET_ALL handling block: Remove REQ_OP_ZONE_RESET plugging ...
This commit is contained in:
@@ -120,9 +120,11 @@ struct blk_zone_report {
|
||||
};
|
||||
|
||||
/**
|
||||
* struct blk_zone_range - BLKRESETZONE ioctl request
|
||||
* @sector: starting sector of the first zone to issue reset write pointer
|
||||
* @nr_sectors: Total number of sectors of 1 or more zones to reset
|
||||
* struct blk_zone_range - BLKRESETZONE/BLKOPENZONE/
|
||||
* BLKCLOSEZONE/BLKFINISHZONE ioctl
|
||||
* requests
|
||||
* @sector: Starting sector of the first zone to operate on.
|
||||
* @nr_sectors: Total number of sectors of all zones to operate on.
|
||||
*/
|
||||
struct blk_zone_range {
|
||||
__u64 sector;
|
||||
@@ -139,10 +141,19 @@ struct blk_zone_range {
|
||||
* sector range. The sector range must be zone aligned.
|
||||
* @BLKGETZONESZ: Get the device zone size in number of 512 B sectors.
|
||||
* @BLKGETNRZONES: Get the total number of zones of the device.
|
||||
* @BLKOPENZONE: Open the zones in the specified sector range.
|
||||
* The 512 B sector range must be zone aligned.
|
||||
* @BLKCLOSEZONE: Close the zones in the specified sector range.
|
||||
* The 512 B sector range must be zone aligned.
|
||||
* @BLKFINISHZONE: Mark the zones as full in the specified sector range.
|
||||
* The 512 B sector range must be zone aligned.
|
||||
*/
|
||||
#define BLKREPORTZONE _IOWR(0x12, 130, struct blk_zone_report)
|
||||
#define BLKRESETZONE _IOW(0x12, 131, struct blk_zone_range)
|
||||
#define BLKGETZONESZ _IOR(0x12, 132, __u32)
|
||||
#define BLKGETNRZONES _IOR(0x12, 133, __u32)
|
||||
#define BLKOPENZONE _IOW(0x12, 134, struct blk_zone_range)
|
||||
#define BLKCLOSEZONE _IOW(0x12, 135, struct blk_zone_range)
|
||||
#define BLKFINISHZONE _IOW(0x12, 136, struct blk_zone_range)
|
||||
|
||||
#endif /* _UAPI_BLKZONED_H */
|
||||
|
@@ -58,13 +58,20 @@
|
||||
* Valid hint values for F_{GET,SET}_RW_HINT. 0 is "not set", or can be
|
||||
* used to clear any hints previously set.
|
||||
*/
|
||||
#define RWF_WRITE_LIFE_NOT_SET 0
|
||||
#define RWH_WRITE_LIFE_NOT_SET 0
|
||||
#define RWH_WRITE_LIFE_NONE 1
|
||||
#define RWH_WRITE_LIFE_SHORT 2
|
||||
#define RWH_WRITE_LIFE_MEDIUM 3
|
||||
#define RWH_WRITE_LIFE_LONG 4
|
||||
#define RWH_WRITE_LIFE_EXTREME 5
|
||||
|
||||
/*
|
||||
* The originally introduced spelling is remained from the first
|
||||
* versions of the patch set that introduced the feature, see commit
|
||||
* v4.13-rc1~212^2~51.
|
||||
*/
|
||||
#define RWF_WRITE_LIFE_NOT_SET RWH_WRITE_LIFE_NOT_SET
|
||||
|
||||
/*
|
||||
* Types of directory notifications that may be requested.
|
||||
*/
|
||||
|
@@ -113,6 +113,25 @@ struct opal_shadow_mbr {
|
||||
__u64 size;
|
||||
};
|
||||
|
||||
/* Opal table operations */
|
||||
enum opal_table_ops {
|
||||
OPAL_READ_TABLE,
|
||||
OPAL_WRITE_TABLE,
|
||||
};
|
||||
|
||||
#define OPAL_UID_LENGTH 8
|
||||
struct opal_read_write_table {
|
||||
struct opal_key key;
|
||||
const __u64 data;
|
||||
const __u8 table_uid[OPAL_UID_LENGTH];
|
||||
__u64 offset;
|
||||
__u64 size;
|
||||
#define OPAL_TABLE_READ (1 << OPAL_READ_TABLE)
|
||||
#define OPAL_TABLE_WRITE (1 << OPAL_WRITE_TABLE)
|
||||
__u64 flags;
|
||||
__u64 priv;
|
||||
};
|
||||
|
||||
#define IOC_OPAL_SAVE _IOW('p', 220, struct opal_lock_unlock)
|
||||
#define IOC_OPAL_LOCK_UNLOCK _IOW('p', 221, struct opal_lock_unlock)
|
||||
#define IOC_OPAL_TAKE_OWNERSHIP _IOW('p', 222, struct opal_key)
|
||||
@@ -128,5 +147,6 @@ struct opal_shadow_mbr {
|
||||
#define IOC_OPAL_PSID_REVERT_TPR _IOW('p', 232, struct opal_key)
|
||||
#define IOC_OPAL_MBR_DONE _IOW('p', 233, struct opal_mbr_done)
|
||||
#define IOC_OPAL_WRITE_SHADOW_MBR _IOW('p', 234, struct opal_shadow_mbr)
|
||||
#define IOC_OPAL_GENERIC_TABLE_RW _IOW('p', 235, struct opal_read_write_table)
|
||||
|
||||
#endif /* _UAPI_SED_OPAL_H */
|
||||
|
Reference in New Issue
Block a user