From patchwork Wed Sep 25 20:23:04 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bjorn Helgaas X-Patchwork-Id: 2944151 Return-Path: X-Original-To: patchwork-linux-acpi@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 918EDBFF05 for ; Wed, 25 Sep 2013 20:23:25 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id B040F20583 for ; Wed, 25 Sep 2013 20:23:24 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id B15D620574 for ; Wed, 25 Sep 2013 20:23:23 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756080Ab3IYUXL (ORCPT ); Wed, 25 Sep 2013 16:23:11 -0400 Received: from mail-ye0-f176.google.com ([209.85.213.176]:52005 "EHLO mail-ye0-f176.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755969Ab3IYUXI (ORCPT ); Wed, 25 Sep 2013 16:23:08 -0400 Received: by mail-ye0-f176.google.com with SMTP id m4so86551yen.21 for ; Wed, 25 Sep 2013 13:23:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=subject:to:from:cc:date:message-id:in-reply-to:references :user-agent:mime-version:content-type:content-transfer-encoding; bh=lbi2tTQCZmQWZmbkn/yDOUhlX7iJ6UITv9Mp72F6KSg=; b=hcAJrUKKF4vjY//TgzYmKKDNHCM+VlDh0wgGWKBTe2198zpNN7yyNfC48L3Qv/s4Ub os7IJq0dy8HfUhEZ7+gqLOkG1o21aENmWPgZPW6ggjE5jZX0nZMQZT0NzWBjOHxmpzRk dqpuOFdkpcarSCAXmiqGRjbG4xz55PiV93/OcusuB+e69N63FSJ30u4IE6V8Ws25u6HY XMV06Hmg57Lj/J0Rs6F1bSN1pGA7W9cyN1p9RIx3T3pFblQvvousNaKGypBmjWx2zcC6 f207zCYcS5I/diOPk7aslHoVj5cZOr+3GfoycVid85ACpktg+kaNXT+L1QjPM+Fxq44o pVzw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:subject:to:from:cc:date:message-id:in-reply-to :references:user-agent:mime-version:content-type :content-transfer-encoding; bh=lbi2tTQCZmQWZmbkn/yDOUhlX7iJ6UITv9Mp72F6KSg=; b=Mq7xbwZh6ivbDRowIMIMrB8gmMf6tnKHKvNXYjHV4GRGLWOiaZaWAP6vEZzApS+4xh gfpVv+EAOQa/RXUH3ntUNvLKDTWBZirIBJyLMKcwJMd8OBD9HsGvkfXxsVGmI8qOFZcS +d6yclsq62mMVoZpDlBZ/mGJfnF4i2WegcMqmNuC+OYBFhH/6zhOlMcVkZ/V4FVPtJnn zxn0Z6urf5zsScJ20dvlvF25PLzwQvuHZ4qRHxehBMVNpyL+TMZsb9SKHlCEwnwdYOIp ozrQRYnuFHUexA9/BOyuP/eTRyUzLiZrcml2DmtYo4gfJMIccUIEmGUuKDp/BpjgSpo7 4ekg== X-Gm-Message-State: ALoCoQmEAwUILi+gGct7QVmyprM3RbhQOKKYS7rzj+tDUnRHPV9FwkKJmB5USAu41o5rew15b5TcQY1zezfASrLhv+vTtzN5rlbhpA+btqu1f/NA4iZ1pXvQsmpTQbehNd49fm78MIvCBHe8IEekpqlRVj7Tq4BHF64gIv0fGeoZvv6Z3N9t/8KhvFoa0P8AxY8NBOuoCde90KNiE14jyBO5Uyj2pYHdDw== X-Received: by 10.236.149.162 with SMTP id x22mr8040212yhj.65.1380140587184; Wed, 25 Sep 2013 13:23:07 -0700 (PDT) Received: from localhost ([172.16.50.208]) by mx.google.com with ESMTPSA id e39sm56451289yhq.15.1969.12.31.16.00.00 (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Wed, 25 Sep 2013 13:23:06 -0700 (PDT) Subject: [PATCH 1/3] ACPI / hotplug: Set kobject name via kobject_add(), not kobject_set_name() To: "Rafael J. Wysocki" , Len Brown From: Bjorn Helgaas Cc: linux-acpi@vger.kernel.org Date: Wed, 25 Sep 2013 14:23:04 -0600 Message-ID: <20130925202304.18667.26104.stgit@bhelgaas-glaptop.roam.corp.google.com> In-Reply-To: <20130925202037.18667.31220.stgit@bhelgaas-glaptop.roam.corp.google.com> References: <20130925202037.18667.31220.stgit@bhelgaas-glaptop.roam.corp.google.com> User-Agent: StGit/0.16 MIME-Version: 1.0 Sender: linux-acpi-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-acpi@vger.kernel.org X-Spam-Status: No, score=-8.8 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, T_DKIM_INVALID, UNPARSEABLE_RELAY autolearn=unavailable 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 Set the kobject name via kobject_add() instead of using kobject_set_name(), which is deprecated per Documentation/kobject.txt. Signed-off-by: Bjorn Helgaas --- drivers/acpi/sysfs.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) -- To unsubscribe from this list: send the line "unsubscribe linux-acpi" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/drivers/acpi/sysfs.c b/drivers/acpi/sysfs.c index 05306a5..ea68583 100644 --- a/drivers/acpi/sysfs.c +++ b/drivers/acpi/sysfs.c @@ -763,12 +763,9 @@ void acpi_sysfs_add_hotplug_profile(struct acpi_hotplug_profile *hotplug, goto err_out; kobject_init(&hotplug->kobj, &acpi_hotplug_profile_ktype); - error = kobject_set_name(&hotplug->kobj, "%s", name); - if (error) - goto err_out; hotplug->kobj.parent = hotplug_kobj; - error = kobject_add(&hotplug->kobj, hotplug_kobj, NULL); + error = kobject_add(&hotplug->kobj, hotplug_kobj, "%s", name); if (error) goto err_out;