scsi: Use vsprintf extention %pf with builtin_return_address
authorJoe Perches <joe@perches.com>
Tue, 28 Feb 2012 18:49:36 +0000 (10:49 -0800)
committerJiri Kosina <jkosina@suse.cz>
Fri, 6 Apr 2012 00:09:40 +0000 (17:09 -0700)
Emit the function name not the address when possible.

builtin_return_address() gives an address.  When building
a kernel with CONFIG_KALLSYMS, emit the actual function
name not the address.

Signed-off-by: Joe Perches <joe@perches.com>
Acked-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
drivers/scsi/esp_scsi.c

index 394ed9e..34552bf 100644 (file)
@@ -1000,7 +1000,7 @@ static int esp_check_spur_intr(struct esp *esp)
 
 static void esp_schedule_reset(struct esp *esp)
 {
-       esp_log_reset("ESP: esp_schedule_reset() from %p\n",
+       esp_log_reset("ESP: esp_schedule_reset() from %pf\n",
                      __builtin_return_address(0));
        esp->flags |= ESP_FLAG_RESETTING;
        esp_event(esp, ESP_EVENT_RESET);