From 2d2d5e6e287e050c6418165d6907adfa345e2cd5 Mon Sep 17 00:00:00 2001 From: Sun Peng Date: Fri, 28 Aug 2020 02:20:06 +0000 Subject: [PATCH] dm: usb: Convert print output to acrn-dm logger Refine the UPRINTF to pr_* based log interface for better log management. Tracked-On: #5267 Signed-off-by: Sun Peng Reviewed-by: Chi Mingqiang Acked-by: Wang, Yu1 --- devicemodel/include/usb_core.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/devicemodel/include/usb_core.h b/devicemodel/include/usb_core.h index a47d87220..c871a8e80 100644 --- a/devicemodel/include/usb_core.h +++ b/devicemodel/include/usb_core.h @@ -33,6 +33,7 @@ #include #include #include "types.h" +#include "log.h" /* FIXME: * There are some huge data requests which need more than 256 TRBs in a single @@ -215,7 +216,7 @@ enum USB_ERRCODE { #define LDBG 3 #define LVRB 4 #define UPRINTF(lvl, fmt, args...) \ - do { if (lvl <= usb_log_level) printf(LOG_TAG fmt, ##args); } while (0) + do { if (lvl <= usb_log_level) pr_dbg(LOG_TAG fmt, ##args); } while (0) #define NATIVE_USBSYS_DEVDIR "/sys/bus/usb/devices" #define NATIVE_USB2_SPEED "480"