From patchwork Mon Jan 7 04:20:42 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sachin Kamat X-Patchwork-Id: 13853 Return-Path: X-Original-To: patchwork@peony.canonical.com Delivered-To: patchwork@peony.canonical.com Received: from fiordland.canonical.com (fiordland.canonical.com [91.189.94.145]) by peony.canonical.com (Postfix) with ESMTP id B420A23E1F for ; Mon, 7 Jan 2013 04:29:58 +0000 (UTC) Received: from mail-vb0-f48.google.com (mail-vb0-f48.google.com [209.85.212.48]) by fiordland.canonical.com (Postfix) with ESMTP id 52476A19872 for ; Mon, 7 Jan 2013 04:29:58 +0000 (UTC) Received: by mail-vb0-f48.google.com with SMTP id fc21so18478160vbb.7 for ; Sun, 06 Jan 2013 20:29:57 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-received:x-forwarded-to:x-forwarded-for:delivered-to:x-received :received-spf:x-received:from:to:cc:subject:date:message-id:x-mailer :x-gm-message-state; bh=VPPLakMj56ac4QSMLujv5kNZPFY73DG1NfJwLU4yVKo=; b=P8Y8gyeOjev5d9LUupOU8RV+sRrcRL0oSg2/cfuGaQnX6q0wc9qDrtoSQklDrs7XeP ujMKaMwk9uMOBnsjmEdl7vmgXxSwNVZLw92y6zyUqG1nl+T32qXkn3y8QVgLqXmmtQsi XkwmoPtTwyz4kAWVn5ke3RViZpz8FW0Ce43sFrDdRFqwu4FzID5ygVIl+PBCok2Fb0VB HCnbjuBbtj/VJ2LBslYKp1krW5cGVFgxiZYYNT/BsPEkK+g6+gGYkw6waRq15aWMuGlf W6rul/6Hr2lKyClQ2Yv4o8Ixo707vqZOkPO1zmvBHmiAP5qRlnA08IVSwm5d7EBK7vtc Usog== X-Received: by 10.58.74.196 with SMTP id w4mr5201458vev.7.1357532997777; Sun, 06 Jan 2013 20:29:57 -0800 (PST) X-Forwarded-To: linaro-patchwork@canonical.com X-Forwarded-For: patch@linaro.org linaro-patchwork@canonical.com Delivered-To: patches@linaro.org Received: by 10.58.145.101 with SMTP id st5csp45492veb; Sun, 6 Jan 2013 20:29:57 -0800 (PST) X-Received: by 10.68.234.36 with SMTP id ub4mr184356463pbc.68.1357532996580; Sun, 06 Jan 2013 20:29:56 -0800 (PST) Received: from mail-pb0-f52.google.com (mail-pb0-f52.google.com [209.85.160.52]) by mx.google.com with ESMTPS id w3si57919737pbz.108.2013.01.06.20.29.56 (version=TLSv1/SSLv3 cipher=OTHER); Sun, 06 Jan 2013 20:29:56 -0800 (PST) Received-SPF: neutral (google.com: 209.85.160.52 is neither permitted nor denied by best guess record for domain of sachin.kamat@linaro.org) client-ip=209.85.160.52; Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.160.52 is neither permitted nor denied by best guess record for domain of sachin.kamat@linaro.org) smtp.mail=sachin.kamat@linaro.org Received: by mail-pb0-f52.google.com with SMTP id ro2so10284879pbb.25 for ; Sun, 06 Jan 2013 20:29:56 -0800 (PST) X-Received: by 10.68.129.233 with SMTP id nz9mr181197148pbb.139.1357532996076; Sun, 06 Jan 2013 20:29:56 -0800 (PST) Received: from localhost.localdomain ([115.113.119.130]) by mx.google.com with ESMTPS id ho4sm660942pbc.54.2013.01.06.20.29.53 (version=TLSv1/SSLv3 cipher=OTHER); Sun, 06 Jan 2013 20:29:55 -0800 (PST) From: Sachin Kamat To: linux-serial@vger.kernel.org Cc: gregkh@linuxfoundation.org, alan@linux.intel.com, jslaby@suse.cz, sachin.kamat@linaro.org, patches@linaro.org Subject: [PATCH 1/1] serial: Samsung: Use of_match_ptr() macro Date: Mon, 7 Jan 2013 09:50:42 +0530 Message-Id: <1357532442-5896-1-git-send-email-sachin.kamat@linaro.org> X-Mailer: git-send-email 1.7.4.1 X-Gm-Message-State: ALoCoQkSLmqZnbu5TvgNhENln2hL7jrlk0P9Ab2aXC5EAa1gRp1nZ5TP6IkRadAV4rIbeSCF/yhp This eliminates having an #ifdef returning NULL for the case when OF is disabled. Signed-off-by: Sachin Kamat --- drivers/tty/serial/samsung.c | 4 +--- 1 files changed, 1 insertions(+), 3 deletions(-) diff --git a/drivers/tty/serial/samsung.c b/drivers/tty/serial/samsung.c index 12e5249..e393b0a 100644 --- a/drivers/tty/serial/samsung.c +++ b/drivers/tty/serial/samsung.c @@ -1725,8 +1725,6 @@ static const struct of_device_id s3c24xx_uart_dt_match[] = { {}, }; MODULE_DEVICE_TABLE(of, s3c24xx_uart_dt_match); -#else -#define s3c24xx_uart_dt_match NULL #endif static struct platform_driver samsung_serial_driver = { @@ -1737,7 +1735,7 @@ static struct platform_driver samsung_serial_driver = { .name = "samsung-uart", .owner = THIS_MODULE, .pm = SERIAL_SAMSUNG_PM_OPS, - .of_match_table = s3c24xx_uart_dt_match, + .of_match_table = of_match_ptr(s3c24xx_uart_dt_match), }, };