zram: return zram device_id from zram_add()
authorSergey Senozhatsky <sergey.senozhatsky@gmail.com>
Thu, 25 Jun 2015 22:00:19 +0000 (15:00 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Fri, 26 Jun 2015 00:00:36 +0000 (17:00 -0700)
commit92ff15288747b80730f0132e9c98403370c27b34
tree40ccefd330a9a7bef36cf8ff9cd14804ab4cb9f9
parentb31177f2a9d5b2cfb1da7a06a4a98273b40975a8
zram: return zram device_id from zram_add()

This patch prepares zram to enable on-demand device creation.
zram_add() performs automatic device_id assignment and returns
new device id (>= 0) or error code (< 0).

Signed-off-by: Sergey Senozhatsky <sergey.senozhatsky@gmail.com>
Acked-by: Minchan Kim <minchan@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
drivers/block/zram/zram_drv.c