From patchwork Wed Dec 12 11:39:09 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sachin Kamat X-Patchwork-Id: 13503 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 01A1123FCD for ; Wed, 12 Dec 2012 11:46:18 +0000 (UTC) Received: from mail-ie0-f180.google.com (mail-ie0-f180.google.com [209.85.223.180]) by fiordland.canonical.com (Postfix) with ESMTP id A6C2CA183C5 for ; Wed, 12 Dec 2012 11:46:17 +0000 (UTC) Received: by mail-ie0-f180.google.com with SMTP id c10so1603005ieb.11 for ; Wed, 12 Dec 2012 03:46:17 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-forwarded-to:x-forwarded-for:delivered-to:received-spf:from:to:cc :subject:date:message-id:x-mailer:x-gm-message-state; bh=ELYSD3oviiH47ZSDc61Thji0ZTSQRObGBeWaVAiFpFI=; b=DBf7uYGSoBz2EK4QeRDXfw5ktcMsU85PX9qPU3rAmnNV1x/8jogMH15nwUVVQ56Zql caYBUrqp4caWIsIB9M99mrrl88VKVwNws5Dz+c3U2iL6MwmRSGgmp42sDgtK6Gm4lTs9 G6WfzogG7w3X8ISNH1VigcVF4IolcAmj7iel4Gy3A+/hBSuTskmlKc+ikkWOGZKFAfOR ADHlvf7WuPCCmOvZBqR2NZKtoNa0mQCHluOCl+NYoBzBBm67sYhsULiololGS6NtdFPr nxh1lXOI4T9MgZ2USDWUuymFn69Dd8qp/6/I9OXFDWr7oMpaJH/NSY6w1FEmuzLVKCWn 8/9Q== Received: by 10.43.49.199 with SMTP id vb7mr496399icb.6.1355312776887; Wed, 12 Dec 2012 03:46:16 -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.50.67.148 with SMTP id n20csp194114igt; Wed, 12 Dec 2012 03:46:16 -0800 (PST) Received: by 10.68.241.231 with SMTP id wl7mr1993206pbc.164.1355312776257; Wed, 12 Dec 2012 03:46:16 -0800 (PST) Received: from mail-pa0-f52.google.com (mail-pa0-f52.google.com [209.85.220.52]) by mx.google.com with ESMTPS id f9si28321074paz.116.2012.12.12.03.46.16 (version=TLSv1/SSLv3 cipher=OTHER); Wed, 12 Dec 2012 03:46:16 -0800 (PST) Received-SPF: neutral (google.com: 209.85.220.52 is neither permitted nor denied by best guess record for domain of sachin.kamat@linaro.org) client-ip=209.85.220.52; Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.220.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-pa0-f52.google.com with SMTP id fb1so510618pad.39 for ; Wed, 12 Dec 2012 03:46:16 -0800 (PST) Received: by 10.66.85.103 with SMTP id g7mr1923207paz.45.1355312775949; Wed, 12 Dec 2012 03:46:15 -0800 (PST) Received: from localhost.localdomain ([115.113.119.130]) by mx.google.com with ESMTPS id o6sm15688980paw.37.2012.12.12.03.46.12 (version=TLSv1/SSLv3 cipher=OTHER); Wed, 12 Dec 2012 03:46:15 -0800 (PST) From: Sachin Kamat To: rtc-linux@googlegroups.com Cc: a.zummo@towertech.it, akpm@linux-foundation.org, sachin.kamat@linaro.org, patches@linaro.org Subject: [PATCH 1/1] drivers/rtc/rtc-s3c: Use of_match_ptr() macro Date: Wed, 12 Dec 2012 17:09:09 +0530 Message-Id: <1355312349-21064-1-git-send-email-sachin.kamat@linaro.org> X-Mailer: git-send-email 1.7.4.1 X-Gm-Message-State: ALoCoQkNawNn0iomBMZBdEePjxZn+YtesW5zbujaUt6D77zFJV91RkS+W5uzIJbnk3VuVwE6Nioc This eliminates having an #ifdef returning NULL for the case when OF is disabled. Signed-off-by: Sachin Kamat --- drivers/rtc/rtc-s3c.c | 4 +--- 1 files changed, 1 insertions(+), 3 deletions(-) diff --git a/drivers/rtc/rtc-s3c.c b/drivers/rtc/rtc-s3c.c index e33df1b..4bd9414 100644 --- a/drivers/rtc/rtc-s3c.c +++ b/drivers/rtc/rtc-s3c.c @@ -663,8 +663,6 @@ static const struct of_device_id s3c_rtc_dt_match[] = { {}, }; MODULE_DEVICE_TABLE(of, s3c_rtc_dt_match); -#else -#define s3c_rtc_dt_match NULL #endif static struct platform_device_id s3c_rtc_driver_ids[] = { @@ -695,7 +693,7 @@ static struct platform_driver s3c_rtc_driver = { .driver = { .name = "s3c-rtc", .owner = THIS_MODULE, - .of_match_table = s3c_rtc_dt_match, + .of_match_table = of_match_ptr(s3c_rtc_dt_match), }, };