Remove sysfs `num_migrated' attribute. We are moving away from
per-stat device attrs towards 3 stat files that will accumulate
io and mm stats in a format similar to block layer statistics in
/sys/block/<dev>/stat. That will be easier to use in user space,
and reduce the number of syscalls needed to read zram device
statistics.

`num_migrated' will return back in zram<id>/mm_stat file.

Acked-by: Minchan Kim <[email protected]>
Signed-off-by: Sergey Senozhatsky <[email protected]>
---
 Documentation/ABI/testing/sysfs-block-zram | 7 -------
 drivers/block/zram/zram_drv.c              | 2 --
 2 files changed, 9 deletions(-)

diff --git a/Documentation/ABI/testing/sysfs-block-zram 
b/Documentation/ABI/testing/sysfs-block-zram
index bede902..91ad707 100644
--- a/Documentation/ABI/testing/sysfs-block-zram
+++ b/Documentation/ABI/testing/sysfs-block-zram
@@ -149,10 +149,3 @@ Description:
                The compact file is write-only and trigger compaction for
                allocator zrm uses. The allocator moves some objects so that
                it could free fragment space.
-
-What:          /sys/block/zram<id>/num_migrated
-Date:          August 2015
-Contact:       Minchan Kim <[email protected]>
-Description:
-               The compact file is read-only and shows how many object
-               migrated by compaction.
diff --git a/drivers/block/zram/zram_drv.c b/drivers/block/zram/zram_drv.c
index 0194799..660999f 100644
--- a/drivers/block/zram/zram_drv.c
+++ b/drivers/block/zram/zram_drv.c
@@ -392,7 +392,6 @@ ZRAM_ATTR_RO(invalid_io);
 ZRAM_ATTR_RO(notify_free);
 ZRAM_ATTR_RO(zero_pages);
 ZRAM_ATTR_RO(compr_data_size);
-ZRAM_ATTR_RO(num_migrated);
 
 static inline bool zram_meta_get(struct zram *zram)
 {
@@ -1069,7 +1068,6 @@ static struct attribute *zram_disk_attrs[] = {
        &dev_attr_num_writes.attr,
        &dev_attr_failed_reads.attr,
        &dev_attr_failed_writes.attr,
-       &dev_attr_num_migrated.attr,
        &dev_attr_compact.attr,
        &dev_attr_invalid_io.attr,
        &dev_attr_notify_free.attr,
-- 
2.3.2.223.g7a9409c

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Reply via email to