Re: [PATCH] libata-core.c: restore configuration boot messages in ata_dev_configure()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Tejun Heo wrote:
Actually, how about...

enum {
    ATA_MSG_ERR,
    ATA_MSG_WARNING,
    ...
};

const char *__ata_msg_lvs[] = {
    [ATA_MSG_ERR]        = KERN_ERR,
    [ATA_MSG_WARNING]    = KERN_WARNING,
    ...
};

#define ata_port_printk(ap, lv, fmt, args...) do { \
    if (unlikely((ap)->msg_enable & (1 << (lv))))
        printk(__ata_msg_lvs[lv]"ata%u: "fmt, (ap)->id , #args);

Oops,
	printk("%sata%u: "fmt, __ata_msg_lvs[lv], (ap)->id, #args);

--
tejun
-
: send the line "unsubscribe linux-ide" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Filesystems]     [Linux SCSI]     [Linux RAID]     [Git]     [Kernel Newbies]     [Linux Newbie]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Samba]     [Device Mapper]

  Powered by Linux