Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755708AbaJILb5 (ORCPT ); Thu, 9 Oct 2014 07:31:57 -0400 Received: from mail-la0-f41.google.com ([209.85.215.41]:37047 "EHLO mail-la0-f41.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754831AbaJILbo (ORCPT ); Thu, 9 Oct 2014 07:31:44 -0400 MIME-Version: 1.0 In-Reply-To: <1412659726-29957-2-git-send-email-linux@roeck-us.net> References: <1412659726-29957-1-git-send-email-linux@roeck-us.net> <1412659726-29957-2-git-send-email-linux@roeck-us.net> Date: Thu, 9 Oct 2014 13:31:40 +0200 X-Google-Sender-Auth: jpwkCvafUZ3nfaT--DQh65doIVk Message-ID: Subject: Re: [PATCH 01/44] kernel: Add support for poweroff handler call chain From: Geert Uytterhoeven To: Guenter Roeck Cc: "linux-kernel@vger.kernel.org" , "adi-buildroot-devel@lists.sourceforge.net" , driverdevel , "devicetree@vger.kernel.org" , lguest@lists.ozlabs.org, ACPI Devel Maling List , alpha , "moderated list:PANASONIC MN10300..." , Cris , linux-efi@vger.kernel.org, "open list:QUALCOMM HEXAGON..." , linux-m32r-ja@ml.linux-m32r.org, "linuxppc-dev@lists.ozlabs.org" , linux-s390 , linux-tegra@vger.kernel.org, "linux-xtensa@linux-xtensa.org" , openipmi-developer@lists.sourceforge.net, uml-devel , "linux-arm-kernel@lists.infradead.org" , linux-c6x-dev@linux-c6x.org, "linux-ia64@vger.kernel.org" , linux-m68k , "open list:METAG ARCHITECTURE" , Linux MIPS Mailing List , Parisc List , Linux PM list , Linux-sh list , xen-devel@lists.xenproject.org, Andrew Morton , Heiko Stuebner , Romain Perier , "Rafael J. Wysocki" , Len Brown , Pavel Machek , Alexander Graf Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Oct 7, 2014 at 7:28 AM, Guenter Roeck wrote: > +int register_poweroff_handler_simple(void (*handler)(void), int priority) > +{ > + char symname[KSYM_NAME_LEN]; > + > + if (poweroff_handler_data.handler) { > + lookup_symbol_name((unsigned long)poweroff_handler_data.handler, > + symname); > + pr_warn("Poweroff function already registered (%s)", symname); > + lookup_symbol_name((unsigned long)handler, symname); > + pr_cont(", cannot register %s\n", symname); Doesn't %ps work to look up symbols? pr_warn("Poweroff function already registered (%ps), cannot register %ps\n", poweroff_handler_data.handler, handler); > + return -EBUSY; > + } Gr{oetje,eeting}s, Geert -- Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org In personal conversations with technical people, I call myself a hacker. But when I'm talking to journalists I just say "programmer" or something like that. -- Linus Torvalds -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/