From patchwork Wed Dec 19 08:50:58 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sachin Kamat X-Patchwork-Id: 1895041 X-Patchwork-Delegate: rui.zhang@intel.com Return-Path: X-Original-To: patchwork-linux-pm@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork1.kernel.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by patchwork1.kernel.org (Postfix) with ESMTP id 1F1C73FC66 for ; Wed, 19 Dec 2012 09:22:13 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752892Ab2LSJWM (ORCPT ); Wed, 19 Dec 2012 04:22:12 -0500 Received: from mail-pa0-f44.google.com ([209.85.220.44]:60085 "EHLO mail-pa0-f44.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751035Ab2LSJWL (ORCPT ); Wed, 19 Dec 2012 04:22:11 -0500 X-Greylist: delayed 1426 seconds by postgrey-1.27 at vger.kernel.org; Wed, 19 Dec 2012 04:22:11 EST Received: by mail-pa0-f44.google.com with SMTP id hz11so1174595pad.17 for ; Wed, 19 Dec 2012 01:22:10 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-received:from:to:cc:subject:date:message-id:x-mailer :x-gm-message-state; bh=rtF8qnrEa68AH5TCJ1oLiPmOT/JD6C3Vm+fJyO0iDJ8=; b=hr80wGlrf6gOdLyLoSbIzxYgTJvw6sasm3wSNJz5bQ7JyDRBCUrQDDXrXstSxZI0i2 h4Rf5fyrOoCrANPmUxtoa+KZ55ZZJZrJ7rh6hXxjuF0N4HlDSCOhsF77do5sfT8aeF1S qUcDaQfFQ8VYAQ2Ln6KtCooR+7ZkHh9/hYfQkYWsahWzqkXahzdO4FFklMe7KCc9V4iV H90Z1KwadJKHhhEZ3xl2WhUEXp0CLbCbYKI2PVR1hY+69+jEyOGB6A5SiKtTb00Ay/80 En27ZAt7NliZBKG7jOAaTet6T+oUJY8gYvcW/hRl5ZkBnSt00vUS/c9LsfxOcnm+3iRh XF3Q== X-Received: by 10.68.243.33 with SMTP id wv1mr10611706pbc.143.1355907504274; Wed, 19 Dec 2012 00:58:24 -0800 (PST) Received: from localhost.localdomain ([115.113.119.130]) by mx.google.com with ESMTPS id p10sm3078009pax.27.2012.12.19.00.58.20 (version=TLSv1/SSLv3 cipher=OTHER); Wed, 19 Dec 2012 00:58:23 -0800 (PST) From: Sachin Kamat To: linux-pm@vger.kernel.org Cc: rui.zhang@intel.com, hongbo.zhang@linaro.org, sachin.kamat@linaro.org, patches@linaro.org, Hongbo Zhang Subject: [PATCH 1/2] thermal: db8500: Use of_match_ptr() macro in db8500_thermal.c Date: Wed, 19 Dec 2012 14:20:58 +0530 Message-Id: <1355907059-28720-1-git-send-email-sachin.kamat@linaro.org> X-Mailer: git-send-email 1.7.4.1 X-Gm-Message-State: ALoCoQn1JtmLjRmReNQM5wraY1oPDSGIQXuUqHFs75791akLa+26dWYIEg3L5f9PjqUjw02XBSbi Sender: linux-pm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pm@vger.kernel.org This eliminates having an #ifdef returning NULL for the case when OF is disabled. Cc: Hongbo Zhang Signed-off-by: Sachin Kamat Reviewed-by: hongbo.zhang@linaro.org --- Compile tested on linux-next. --- drivers/thermal/db8500_thermal.c | 4 +--- 1 files changed, 1 insertions(+), 3 deletions(-) diff --git a/drivers/thermal/db8500_thermal.c b/drivers/thermal/db8500_thermal.c index ec71ade..61ce60a 100644 --- a/drivers/thermal/db8500_thermal.c +++ b/drivers/thermal/db8500_thermal.c @@ -508,15 +508,13 @@ static const struct of_device_id db8500_thermal_match[] = { { .compatible = "stericsson,db8500-thermal" }, {}, }; -#else -#define db8500_thermal_match NULL #endif static struct platform_driver db8500_thermal_driver = { .driver = { .owner = THIS_MODULE, .name = "db8500-thermal", - .of_match_table = db8500_thermal_match, + .of_match_table = of_match_ptr(db8500_thermal_match), }, .probe = db8500_thermal_probe, .suspend = db8500_thermal_suspend,