Re: [PATCHv2 07/10] zram: report every added and removed device

Sergey Senozhatsky
2015-04-23T04:23:29Z

On (04/23/15 11:38), Minchan Kim wrote:
> > +
> > + pr_info("Removed device: %s\n", zram->disk->disk_name);
>
> trivial:
>
> why did you add the info in the middle of logic functions?
> Without special reason, let's add it top of the zram_remove.
>

ok.

-ss

> Acked-by: Minchan Kim <minchan@kernel.org>
>
> > del_gendisk(zram->disk);
> > put_disk(zram->disk);
> > kfree(zram);
> > @@ -1281,7 +1285,6 @@ static void destroy_devices(void)
> > idr_for_each(&zram_index_idr, &zram_exit_cb, NULL);
> > idr_destroy(&zram_index_idr);
> > unregister_blkdev(zram_major, "zram");
> > - pr_info("Destroyed device(s)\n");
> > }
> >
> > static int __init zram_init(void)
> > @@ -1300,7 +1303,6 @@ static int __init zram_init(void)
> > goto out_error;
> > }
> >
> > - pr_info("Created %u device(s)\n", num_devices);
> > return 0;
> >
> > out_error:
> > --
> > 2.4.0.rc2
> >
>
> --
> Kind regards,
> Minchan Kim
>