summaryrefslogtreecommitdiff
path: root/drivers/staging/fbtft
diff options
context:
space:
mode:
authorGeliang Tang <geliangtang@163.com>2015-12-27 21:15:46 +0800
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2016-02-07 19:42:23 -0800
commitf6bfc25ee0f60aa6ada33b3948a9aa3aecc6ef6a (patch)
treee5c5bc14d6f2de3688ee2515c638d84f6cf87976 /drivers/staging/fbtft
parent5d5ccf21968d0de82f3eed9ab924fadbc872e739 (diff)
staging: fbtft: use to_platform_device()
Use to_platform_device() instead of open-coding it. Signed-off-by: Geliang Tang <geliangtang@163.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/fbtft')
-rw-r--r--drivers/staging/fbtft/fbtft_device.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/staging/fbtft/fbtft_device.c b/drivers/staging/fbtft/fbtft_device.c
index 08d0597ced5b..241d7c6bebde 100644
--- a/drivers/staging/fbtft/fbtft_device.c
+++ b/drivers/staging/fbtft/fbtft_device.c
@@ -1330,7 +1330,7 @@ static void pr_spi_devices(void)
static int p_device_found(struct device *dev, void *data)
{
struct platform_device
- *pdev = container_of(dev, struct platform_device, dev);
+ *pdev = to_platform_device(dev);
if (strstr(pdev->name, "fb"))
dev_info(dev, "%s id=%d pdata? %s\n", pdev->name, pdev->id,