BACKPORT: tty: goldfish: support platform_device with id -1
authorGreg Hackmann <ghackmann@google.com>
Fri, 26 Feb 2016 19:01:05 +0000 (19:01 +0000)
committerAmit Pundir <amit.pundir@linaro.org>
Thu, 1 Dec 2016 09:48:44 +0000 (15:18 +0530)
commit44a4608e6a9848af3e641ea5cb63b5353eda22e2
tree468cf5f63fdb14d6ad992a6d5661931dc5532747
parent5f07edb06fc080f495924a8d03410dab207e2dbf
BACKPORT: tty: goldfish: support platform_device with id -1

When the platform bus sets the platform_device id to -1 (PLATFORM_DEVID_NONE),
use an incrementing counter for the TTY index instead

Signed-off-by: Greg Hackmann <ghackmann@google.com>
Signed-off-by: Jin Qian <jinqian@android.com>
Signed-off-by: Alan Cox <alan@linux.intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
(cherry picked from commit 465893e18878e119d8d0255439fad8debbd646fd)

Change-Id: Ifec5ee9d71c7c076e59bb7af77c0184d1b1383cb
drivers/tty/goldfish.c