block_dev: Convert to new API
PATCH v2 1/1 block_dev: Convert to new API
Signed-off-by Ricardo B. Marliere <[email protected]>
---v1->v2:
- Added ifdef for including genhd.h in older kernels
- Removed unused pointer
- Fixed make check linter warnings
- Link to v1: https://lore.kernel.org/r/[email protected]
v1:
- Tested against v6.11
--- .../block/block_dev_kernel/ltp_block_dev.c | 4 +- .../block/block_dev_user/block_dev.c | 77 +++++++++------------- 2 files changed, 34 insertions(+), 47 deletions(-)
testcases/kernel/device-drivers/block/block_dev_kernel/ltp_block_dev.c +3 -1
@@ -12,8 +12,10 @@#include <linux/module.h> #include <linux/device.h> #include <linux/fs.h> -#include <linux/genhd.h> #include <linux/blkdev.h> +#ifndef DISK_NAME_LEN +#include <linux/genhd.h> +#endif MODULE_AUTHOR ("Márton Németh <[email protected]>" );MODULE_AUTHOR ("Copyright (c) 2013 Oracle and/or its affiliates" );
testcases/kernel/device-drivers/block/block_dev_user/block_dev.c +31 -46
108 lines not on this page · raw message
---
base-commit: 47aff4decc81ac837fd745278def6883fc2f197b
change-id: 20241018-block_dev-c322152e03ad
Best regards,
Signature · 5 lines
Ricardo B. Marliere <[email protected]> -- Mailing list info: https://lists.linux.it/listinfo/ltp
Hi!
Pushed with a minor changes, thanks.
Since you added SPDX identifier I've removed the long license text and also converted the description to docparse comment.
Signature · 5 lines
Cyril Hrubis [email protected] -- Mailing list info: https://lists.linux.it/listinfo/ltp