[PATCH 1/7] pci: Use standard pr_debug

Jean-Christophe PLAGNIOL-VILLARD plagnioj at jcrosoft.com
Wed Mar 18 02:08:53 PDT 2015


On 07:38 Tue 17 Mar     , Sascha Hauer wrote:
> Use pr_debug instead of custom DBG macro.
> 
> Signed-off-by: Sascha Hauer <s.hauer at pengutronix.de>
> ---
>  drivers/pci/pci.c | 34 +++++++++++++++-------------------
>  1 file changed, 15 insertions(+), 19 deletions(-)
> 
> diff --git a/drivers/pci/pci.c b/drivers/pci/pci.c
> index 1f5dc78..cb8c539 100644
> --- a/drivers/pci/pci.c
> +++ b/drivers/pci/pci.c
> @@ -1,13 +1,9 @@
> +#define pr_fmt(fmt)  "pci: " fmt
> +
>  #include <common.h>
>  #include <linux/sizes.h>
>  #include <linux/pci.h>
>  
> -#ifdef DEBUG
> -#define DBG(x...) printk(x)
> -#else
> -#define DBG(x...)
> -#endif
> -
>  static struct pci_controller *hose_head, **hose_tail = &hose_head;
>  
>  LIST_HEAD(pci_root_buses);
> @@ -150,16 +146,16 @@ static void setup_device(struct pci_dev *dev, int max_bar)
>  		pci_read_config_dword(dev, PCI_BASE_ADDRESS_0 + bar * 4, &mask);
>  
>  		if (mask == 0 || mask == 0xffffffff) {
> -			DBG("  PCI: pbar%d set bad mask\n", bar);
> +			pr_debug("pbar%d set bad mask\n", bar);
dev_debug

please

Best Regards,
J.



More information about the barebox mailing list