Gitweb:     
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=86dae0154a49b67c908faffeb33ba37eddceba74
Commit:     86dae0154a49b67c908faffeb33ba37eddceba74
Parent:     03d1d99c55649ca641b86d2e3489b167ede1671a
Author:     Márton Németh <[EMAIL PROTECTED]>
AuthorDate: Wed Jan 23 22:33:06 2008 -0500
Committer:  Len Brown <[EMAIL PROTECTED]>
CommitDate: Wed Jan 23 22:33:06 2008 -0500

    ACPI: EC: add leading zeros to debug messages
    
    Add leading zeros to pr_debug() calls. For example if x=0x0a, the format
    "0x%2x" will result the string "0x a", the format "0x%2.2x" will result 
"0x0a".
    
    Signed-off-by: Márton Németh <[EMAIL PROTECTED]>
    Signed-off-by: Len Brown <[EMAIL PROTECTED]>
---
 drivers/acpi/ec.c |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/drivers/acpi/ec.c b/drivers/acpi/ec.c
index 8917d75..06c9f35 100644
--- a/drivers/acpi/ec.c
+++ b/drivers/acpi/ec.c
@@ -139,26 +139,26 @@ static struct acpi_ec {
 static inline u8 acpi_ec_read_status(struct acpi_ec *ec)
 {
        u8 x = inb(ec->command_addr);
-       pr_debug(PREFIX "---> status = 0x%2x\n", x);
+       pr_debug(PREFIX "---> status = 0x%2.2x\n", x);
        return x;
 }
 
 static inline u8 acpi_ec_read_data(struct acpi_ec *ec)
 {
        u8 x = inb(ec->data_addr);
-       pr_debug(PREFIX "---> data = 0x%2x\n", x);
+       pr_debug(PREFIX "---> data = 0x%2.2x\n", x);
        return inb(ec->data_addr);
 }
 
 static inline void acpi_ec_write_cmd(struct acpi_ec *ec, u8 command)
 {
-       pr_debug(PREFIX "<--- command = 0x%2x\n", command);
+       pr_debug(PREFIX "<--- command = 0x%2.2x\n", command);
        outb(command, ec->command_addr);
 }
 
 static inline void acpi_ec_write_data(struct acpi_ec *ec, u8 data)
 {
-       pr_debug(PREFIX "<--- data = 0x%2x\n", data);
+       pr_debug(PREFIX "<--- data = 0x%2.2x\n", data);
        outb(data, ec->data_addr);
 }
 
-
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to