From patchwork Tue Nov 6 15:02:09 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Toshi Kani X-Patchwork-Id: 1704881 Return-Path: X-Original-To: patchwork-linux-acpi@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 5E07940D29 for ; Tue, 6 Nov 2012 15:10:59 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751175Ab2KFPKf (ORCPT ); Tue, 6 Nov 2012 10:10:35 -0500 Received: from g6t0185.atlanta.hp.com ([15.193.32.62]:46419 "EHLO g6t0185.atlanta.hp.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752488Ab2KFPK2 (ORCPT ); Tue, 6 Nov 2012 10:10:28 -0500 Received: from g5t0029.atlanta.hp.com (g5t0029.atlanta.hp.com [16.228.8.141]) by g6t0185.atlanta.hp.com (Postfix) with ESMTP id 1B9B6242A2; Tue, 6 Nov 2012 15:10:23 +0000 (UTC) Received: from misato.fc.hp.com (misato.fc.hp.com [16.71.12.41]) by g5t0029.atlanta.hp.com (Postfix) with ESMTP id 61E90200AD; Tue, 6 Nov 2012 15:10:22 +0000 (UTC) From: Toshi Kani To: linux-acpi@vger.kernel.org, rjw@sisk.pl, lenb@kernel.org Cc: linux-kernel@vger.kernel.org, joe@perches.com, bhelgaas@google.com, isimatu.yasuaki@jp.fujitsu.com, vijaymohan.pandarathil@hp.com, imammedo@redhat.com, prarit@redhat.com, Toshi Kani Subject: [PATCH v5 RESEND 4/5] ACPI: Update Container hotplug error messages Date: Tue, 6 Nov 2012 08:02:09 -0700 Message-Id: <1352214130-12055-5-git-send-email-toshi.kani@hp.com> X-Mailer: git-send-email 1.7.11.7 In-Reply-To: <1352214130-12055-1-git-send-email-toshi.kani@hp.com> References: <1352214130-12055-1-git-send-email-toshi.kani@hp.com> Sender: linux-acpi-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-acpi@vger.kernel.org Updated Container hotplug error messages with acpi_pr_() and pr_(). Removed an unnecessary check to device pointer in acpi_container_add(). Signed-off-by: Toshi Kani --- drivers/acpi/container.c | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/drivers/acpi/container.c b/drivers/acpi/container.c index 69e2d6b..71d77ab 100644 --- a/drivers/acpi/container.c +++ b/drivers/acpi/container.c @@ -110,12 +110,6 @@ static int acpi_container_add(struct acpi_device *device) { struct acpi_container *container; - - if (!device) { - printk(KERN_ERR PREFIX "device is NULL\n"); - return -EINVAL; - } - container = kzalloc(sizeof(struct acpi_container), GFP_KERNEL); if (!container) return -ENOMEM; @@ -177,7 +171,7 @@ static void container_notify_cb(acpi_handle handle, u32 type, void *context) case ACPI_NOTIFY_BUS_CHECK: /* Fall through */ case ACPI_NOTIFY_DEVICE_CHECK: - printk(KERN_WARNING "Container driver received %s event\n", + pr_debug("Container driver received %s event\n", (type == ACPI_NOTIFY_BUS_CHECK) ? "ACPI_NOTIFY_BUS_CHECK" : "ACPI_NOTIFY_DEVICE_CHECK"); @@ -198,7 +192,7 @@ static void container_notify_cb(acpi_handle handle, u32 type, void *context) result = container_device_add(&device, handle); if (result) { - printk(KERN_WARNING "Failed to add container\n"); + acpi_pr_warn(handle, "Failed to add container\n"); break; }