Message ID | 1559577023-558-35-git-send-email-suzuki.poulose@arm.com |
---|---|
State | New |
Headers | show
Delivered-To: patch@linaro.org Received: by 2002:a92:9e1a:0:0:0:0:0 with SMTP id q26csp4644764ili; Mon, 3 Jun 2019 08:51:59 -0700 (PDT) X-Google-Smtp-Source: APXvYqx5ijeK+DIaKXCN2tLKyeBMtr6ixRBP8K697hUNQTKxdTnX7Heevp5e8Lu3r0VthnUDh4Eh X-Received: by 2002:a62:65c7:: with SMTP id z190mr32233249pfb.73.1559577119794; Mon, 03 Jun 2019 08:51:59 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1559577119; cv=none; d=google.com; s=arc-20160816; b=xv9j3EOeF1mVFay1WU1QP5AAI5bTSgOFjvzAAqHNVkBnlI/pzk7ZAIIWh3ohLhN8eE JMW8LB4jcH0oL2WM92CZgWyFMFouBjxIYsbIPQi+p1emN2IjihuVguqNdpuSrRZQPAk1 uVjunEItMv+H1TISALneqmHRSxw8VSTmmNi9zZq4bsMBrL+PijDa2u0SeYhT1xUWzlOS Zln/XrFjtjpDxxYQ+OG/XAmKlLU240idHWYZjWWeIUFyEfda6A2EKbqkkDGUOONbWaRp 1j1yXtMADHe4ctkd2UigRMCzUVIP65WXAHyBOe+a6vToFymWvdwgfRQvBK5tKwoJLnqm EA3g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from; bh=3lJFDfD0a4hD1QRzwyvzWs4Hr/If6NmQW4/kfQJjgns=; b=PhmRhteRRePZb9oOXz/Gou4+eqQgj/iaohHAYloBeOZzImRnVfqDyjDeF43nMfgb14 F+oYI9yU9SC2iDopjbmt3mD5jeQ5/LmSxBVLnKV63wd3OHRs6rT/7Suyh6Lh5URLYWFV cLNlQMcAJQOuG8fqx5nhA7bXgC29FKJBhxA/NpXwkh8LYiJjLye1U8Lb/uhw+wViN4yW LP5Q+4gzQNRQSKtrqOyUtvvGPzQSb+2x29OvzGS8S6yNInvJ15V76K/F2fpNDaP57qE3 HFx5T8tMCAzKiEA2AJezObxsX3VHRESZhlpJhXhaNMwknm01laB9+5DiIKedH1oaFfmB s9Fg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: <linux-kernel-owner@vger.kernel.org> Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id v20si19320578pgk.58.2019.06.03.08.51.59; Mon, 03 Jun 2019 08:51:59 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729454AbfFCPv6 (ORCPT <rfc822;mike.holmes@linaro.org> + 30 others); Mon, 3 Jun 2019 11:51:58 -0400 Received: from foss.arm.com ([217.140.101.70]:53886 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729419AbfFCPvv (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Mon, 3 Jun 2019 11:51:51 -0400 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.72.51.249]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 8C60F1B4B; Mon, 3 Jun 2019 08:51:51 -0700 (PDT) Received: from en101.cambridge.arm.com (en101.cambridge.arm.com [10.1.196.93]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPA id 2C1783F246; Mon, 3 Jun 2019 08:51:50 -0700 (PDT) From: Suzuki K Poulose <suzuki.poulose@arm.com> To: linux-kernel@vger.kernel.org Cc: gregkh@linuxfoundation.org, rafael@kernel.org, suzuki.poulose@arm.com, Alexander Aring <alex.aring@gmail.com>, Stefan Schmidt <stefan@datenfreihafen.org>, linux-wpan@vger.kernel.org Subject: [RFC PATCH 34/57] drivers: ieee802154: Use class_find_device_by_name() helper Date: Mon, 3 Jun 2019 16:50:00 +0100 Message-Id: <1559577023-558-35-git-send-email-suzuki.poulose@arm.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1559577023-558-1-git-send-email-suzuki.poulose@arm.com> References: <1559577023-558-1-git-send-email-suzuki.poulose@arm.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org |
Series |
[RFC,01/57] drivers: s390/cio: Use driver_for_each_device
|
expand
|
diff --git a/net/ieee802154/core.c b/net/ieee802154/core.c index 60b7ac5..26fe751 100644 --- a/net/ieee802154/core.c +++ b/net/ieee802154/core.c @@ -23,11 +23,6 @@ LIST_HEAD(cfg802154_rdev_list); int cfg802154_rdev_list_generation; -static int wpan_phy_match(struct device *dev, const void *data) -{ - return !strcmp(dev_name(dev), (const char *)data); -} - struct wpan_phy *wpan_phy_find(const char *str) { struct device *dev; @@ -35,7 +30,7 @@ struct wpan_phy *wpan_phy_find(const char *str) if (WARN_ON(!str)) return NULL; - dev = class_find_device(&wpan_phy_class, NULL, str, wpan_phy_match); + dev = class_find_device_by_name(&wpan_phy_class, NULL, str); if (!dev) return NULL;
Use the new class_find_device_by_name() helper. Cc: Alexander Aring <alex.aring@gmail.com> Cc: Stefan Schmidt <stefan@datenfreihafen.org> Cc: linux-wpan@vger.kernel.org Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com> --- net/ieee802154/core.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) -- 2.7.4