From patchwork Fri Jan 1 12:03:43 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Geliang Tang X-Patchwork-Id: 7938951 X-Patchwork-Delegate: kvalo@adurom.com Return-Path: X-Original-To: patchwork-linux-wireless@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id DDDC8BEEE5 for ; Fri, 1 Jan 2016 12:04:56 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 1E5DE20529 for ; Fri, 1 Jan 2016 12:04:56 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 4FF7E201BB for ; Fri, 1 Jan 2016 12:04:55 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751750AbcAAMEZ (ORCPT ); Fri, 1 Jan 2016 07:04:25 -0500 Received: from m50-135.163.com ([123.125.50.135]:58224 "EHLO m50-135.163.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751476AbcAAMEX (ORCPT ); Fri, 1 Jan 2016 07:04:23 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=163.com; s=s110527; h=From:Subject:Date:Message-Id; bh=gBdo6GsgF2ioUjJRZh 7ya6dNRKiOe454nZY7lMk3xp4=; b=NAPQA7Nz+tMic+hd13MOvK+duBS3SpnuGz XhoG/36c0+fl/hmE4H21nK66qdAQZN0UIxr55PwyCpqnXKOx6svZtP09al78twIh hWCIfU7x35inZm1Wv2I21EtBvZA+Vn1h4mdkho84Q+2XXIl5i7tWNTP10yKG1tvK I6eHDiWJg= Received: from localhost (unknown [116.77.129.183]) by smtp5 (Coremail) with SMTP id D9GowADHCNQja4ZWCEjeCQ--.45547S3; Fri, 01 Jan 2016 20:03:49 +0800 (CST) From: Geliang Tang To: Stanislav Yakovlev , Kalle Valo Cc: Geliang Tang , linux-wireless@vger.kernel.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v2] ipw2x00: use to_pci_dev() Date: Fri, 1 Jan 2016 20:03:43 +0800 Message-Id: X-Mailer: git-send-email 2.5.0 X-CM-TRANSID: D9GowADHCNQja4ZWCEjeCQ--.45547S3 X-Coremail-Antispam: 1Uf129KBjvdXoW7XFWxJFyxtry8urW7WFWkCrg_yoWfWrX_Zr nFyFs7XryrJ3WF9r43CrWIyryjka40qw48WrZ7try5Ka1fZr4DCr98Zry2qFWFgr1DAryY yrn7GF1rCrZ0kjkaLaAFLSUrUUUUUb8apTn2vfkv8UJUUUU8Yxn0WfASr-VFAUDa7-sFnT 9fnUUvcSsGvfC2KfnxnUUI43ZEXa7IUbJUUUUUUUU== X-Originating-IP: [116.77.129.183] X-CM-SenderInfo: 5jhoxtpqjwt0rj6rljoofrz/1tbiMAbimVWBTeX9ywAAsH Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org X-Spam-Status: No, score=-6.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, FREEMAIL_FROM,RCVD_IN_DNSWL_HI,RP_MATCHES_RCVD,T_DKIM_INVALID, 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 Use to_pci_dev() instead of open-coding it. Signed-off-by: Geliang Tang --- This patch is against net-next tree. Changes in v2: - fix wrong title. --- drivers/net/wireless/intel/ipw2x00/ipw2100.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/wireless/intel/ipw2x00/ipw2100.c b/drivers/net/wireless/intel/ipw2x00/ipw2100.c index 36818c7..121294f 100644 --- a/drivers/net/wireless/intel/ipw2x00/ipw2100.c +++ b/drivers/net/wireless/intel/ipw2x00/ipw2100.c @@ -3514,7 +3514,7 @@ static void ipw2100_msg_free(struct ipw2100_priv *priv) static ssize_t show_pci(struct device *d, struct device_attribute *attr, char *buf) { - struct pci_dev *pci_dev = container_of(d, struct pci_dev, dev); + struct pci_dev *pci_dev = to_pci_dev(d); char *out = buf; int i, j; u32 val;