From patchwork Sun Sep 29 08:51:04 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lars-Peter Clausen X-Patchwork-Id: 2959991 Return-Path: X-Original-To: patchwork-linux-media@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 62A7F9F1BF for ; Sun, 29 Sep 2013 08:50:45 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 96CAD2024A for ; Sun, 29 Sep 2013 08:50:44 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id CEADA201FD for ; Sun, 29 Sep 2013 08:50:43 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755038Ab3I2Ium (ORCPT ); Sun, 29 Sep 2013 04:50:42 -0400 Received: from smtp-out-220.synserver.de ([212.40.185.220]:1375 "EHLO smtp-out-220.synserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754826Ab3I2Itp (ORCPT ); Sun, 29 Sep 2013 04:49:45 -0400 Received: (qmail 2555 invoked by uid 0); 29 Sep 2013 08:49:44 -0000 X-SynServer-TrustedSrc: 1 X-SynServer-AuthUser: lars@metafoo.de X-SynServer-PPID: 1782 Received: from ppp-88-217-66-240.dynamic.mnet-online.de (HELO lars-adi-laptop.fritz.box) [88.217.66.240] by 217.119.54.77 with SMTP; 29 Sep 2013 08:49:42 -0000 From: Lars-Peter Clausen To: Wolfram Sang , David Airlie , Mauro Carvalho Chehab , Jaroslav Kysela , Takashi Iwai , Liam Girdwood , Mark Brown Cc: linux-kernel@vger.kernel.org, linux-i2c@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-media@vger.kernel.org, alsa-devel@alsa-project.org, Lars-Peter Clausen Subject: [PATCH 6/8] ALSA: ppc: keywest: Don't use i2c_client->driver Date: Sun, 29 Sep 2013 10:51:04 +0200 Message-Id: <1380444666-12019-7-git-send-email-lars@metafoo.de> X-Mailer: git-send-email 1.8.0 In-Reply-To: <1380444666-12019-1-git-send-email-lars@metafoo.de> References: <1380444666-12019-1-git-send-email-lars@metafoo.de> Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00,KHOP_BIG_TO_CC, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP The 'driver' field of the i2c_client struct is redundant and is going to be removed. Use 'to_i2c_driver(client->dev.driver)' instead to get direct access to the i2c_driver struct. Signed-off-by: Lars-Peter Clausen Acked-by: Takashi Iwai --- sound/ppc/keywest.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sound/ppc/keywest.c b/sound/ppc/keywest.c index 01aecc2..0d1c27e 100644 --- a/sound/ppc/keywest.c +++ b/sound/ppc/keywest.c @@ -65,7 +65,7 @@ static int keywest_attach_adapter(struct i2c_adapter *adapter) * already bound. If not it means binding failed, and then there * is no point in keeping the device instantiated. */ - if (!keywest_ctx->client->driver) { + if (!keywest_ctx->client->dev.driver) { i2c_unregister_device(keywest_ctx->client); keywest_ctx->client = NULL; return -ENODEV; @@ -76,7 +76,7 @@ static int keywest_attach_adapter(struct i2c_adapter *adapter) * This is safe because i2c-core holds the core_lock mutex for us. */ list_add_tail(&keywest_ctx->client->detected, - &keywest_ctx->client->driver->clients); + &to_i2c_driver(keywest_ctx->client->dev.driver)->clients); return 0; }