Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp1727464yba; Sat, 27 Apr 2019 05:58:05 -0700 (PDT) X-Google-Smtp-Source: APXvYqz7sOlQxH/wcSp2vyBZnxKPG6LuadlAsYWG+KMcf8gg484xC10TyX3wJpd7vZbHHP5xfb8Y X-Received: by 2002:a17:902:20c6:: with SMTP id v6mr49296659plg.276.1556369885055; Sat, 27 Apr 2019 05:58:05 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1556369885; cv=none; d=google.com; s=arc-20160816; b=E5foWS4LknxhJVUPvJDRiWnfAEyUYAFzwHGJJZrknQeqjpW8aJH+ZN2UOL+OgtHHVS KLxgmpLUgEhNmqvh9pSjT/gL13gjJvtQP4YAJNGpYxToSVoodyGlk3N+5dAQTKdWvURL 65Y0h9GVE4Y6tCyuig7cHLxKu61CSrPg2AOyEQDYu5ua4/L2PiXYtQ/ANL0/0xoFLEtj x0OWsJzhP3aA3rCK4q2Wf5Qs5rwUKZi3kbmSdunOG/XJ1a6kfmfbQqRK20p7qZFDFdWm J7wlhDiuWki5bS7N36ljLdkY7aNQmI5wMyRGQfQr6mP4OiDgSwGeQEHf4bpE7b3VZcuD zxog== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from; bh=1aGlu5U1x01n2BZ0yma27n8vlXAyRo8NM1272denZr0=; b=g2MwFMqijCIFznlTSMZRhPDdpDALbaff9XxKZH5xTpBn1skALQnweP0tEnctolO8DX JOA3jLOIIIyULui2aYjZxQg4CLlmeB4voK8pVQ8RA3KiwW3zPo1l4Mtg/BR6+BGCctFg 7BU3ima5STV9154Lw1xq6siBZVrAitSipHP82cpkrQfcLVgz8VtQ+CYOC38N/Ac7m0M1 UEx7PsswVKnHP8Q9QxBlcN06VRkwE/0sSo8UVr+bgGq9yFREAih2zTy+WphjIqrNlyYk iZxTg+5/L/QIYB2c+aY2Sa72m1VFSkjt9eou5weZCvV3IfzlVFCnN3VjktUYfD+9LUaw u0JQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id i96si29070995plb.331.2019.04.27.05.57.50; Sat, 27 Apr 2019 05:58:05 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727584AbfD0MzZ (ORCPT + 99 others); Sat, 27 Apr 2019 08:55:25 -0400 Received: from mout.kundenserver.de ([212.227.126.135]:48977 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727002AbfD0MxR (ORCPT ); Sat, 27 Apr 2019 08:53:17 -0400 Received: from orion.localdomain ([77.2.90.210]) by mrelayeu.kundenserver.de (mreue009 [212.227.15.167]) with ESMTPSA (Nemesis) id 1MPooN-1h7uVt3Uzj-00MrCK; Sat, 27 Apr 2019 14:52:51 +0200 From: "Enrico Weigelt, metux IT consult" To: linux-kernel@vger.kernel.org Cc: gregkh@linuxfoundation.org, andrew@aj.id.au, andriy.shevchenko@linux.intel.com, macro@linux-mips.org, vz@mleia.com, slemieux.tyco@gmail.com, khilman@baylibre.com, liviu.dudau@arm.com, sudeep.holla@arm.com, lorenzo.pieralisi@arm.com, davem@davemloft.net, jacmet@sunsite.dk, linux@prisktech.co.nz, matthias.bgg@gmail.com, linux-mips@vger.kernel.org, linux-serial@vger.kernel.org, linux-ia64@vger.kernel.org, linux-amlogic@lists.infradead.org, linuxppc-dev@lists.ozlabs.org, sparclinux@vger.kernel.org Subject: [PATCH 20/41] drivers: tty: serial: cpm_uart: use dev_err()/dev_warn() instead of printk() Date: Sat, 27 Apr 2019 14:52:01 +0200 Message-Id: <1556369542-13247-21-git-send-email-info@metux.net> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1556369542-13247-1-git-send-email-info@metux.net> References: <1556369542-13247-1-git-send-email-info@metux.net> X-Provags-ID: V03:K1:gPxg0pvaNEeq5x+UwAsDbHdgypnsGOsK9o3j3foMhaID5KFRvEv 8AvtdT3OHQsnwoPSUVUVgaG7uGVOSNulOF2BUp5euWPO4xOffryfhmOQh75bfkqTrattPsp QFI8+vQMDSRQJ10o81AgQsbvofwXHCA01N/KdcAMGoHFdvQFXnI8JYKNCiQeBe0EpQIxX+K rRBN+WvzZqwD0ZWGZ/IRQ== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:2ju8YRhuhXY=:onNlvZ0aDrqH1/5VH3xxRk 97sCatc+DPnq24Zb7ZJM6qAh6b3iT6iWeaqZSLN5g857Y4q/gZkpStxTSY0y7/0vVZ2W2K8eN hrg8KTsBqdMCfc4qz0COMhhaiMomIx6Ezqf1jP899W3P6VFeOiJceFdEaDUqJ2x0mkdvjcSjR P3IZevKXifgjbgM0+HGLwqyrJOuozz0fGHG6voJYrbtD0tdC2lAYE9WFwuLR1ujJzxSkwStdT lkylIMBo9lhsNzylPGYzyv4UI8ZZMZrpvojOg3lgZ0vpcI+NQUoteI0P+Wz5lfIyPfcI+6QP5 bcBDKc9LVTJUAbZrZZUPykDkm6du6zW2r19As2FmM093PScDZCbPR2np4C9780LIVQFScmK7B cS6pvNLxOjZG7VrdBAeBHYqG35dNFeg7Y4G/O2pavGZMM/m9VfYlslnOpQpaOA7biLCwDiZ3g ORABcZsNz/R1affuaIPOyjUXod5AymqWkBo/t+ZeZW+oS7GqagtrFM+tD6HiEmEJQjSZyfhnf bbhVVvk5eNalCXzlFJXa8G2brsHEUR05O/eTzVUCsjKTbU69zjG5Y9jitLl1WIhvZoR1wWDxa R6dA3fagJAV0pXITce+DpVexGE7gqSXQvcl0BHe49TekWK+zRLUg8fQRepiwCRKCXuJeJeQ5m uDJWEO3RV24ra1DasOhJ8L4Y3zxtMI650z5aczoHnbcvIKn7BzWRl4VXH6ecpN1d35iAhdifu qDIdgE2pptfSyvUIDQnzvzrSEC1fksYnQ5U6ig== Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Using dev_err()/dev_warn() instead of printk() for more consistent output. (prints device name, etc). Signed-off-by: Enrico Weigelt --- drivers/tty/serial/cpm_uart/cpm_uart_core.c | 6 +++--- drivers/tty/serial/cpm_uart/cpm_uart_cpm2.c | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/tty/serial/cpm_uart/cpm_uart_core.c b/drivers/tty/serial/cpm_uart/cpm_uart_core.c index b929c7a..374b8bb 100644 --- a/drivers/tty/serial/cpm_uart/cpm_uart_core.c +++ b/drivers/tty/serial/cpm_uart/cpm_uart_core.c @@ -265,7 +265,7 @@ static void cpm_uart_int_rx(struct uart_port *port) * later, which will be the next rx-interrupt or a timeout */ if (tty_buffer_request_room(tport, i) < i) { - printk(KERN_WARNING "No room in flip buffer\n"); + dev_warn(port->dev, "No room in flip buffer\n"); return; } @@ -1155,7 +1155,7 @@ static int cpm_uart_init_port(struct device_node *np, if (!pinfo->clk) { data = of_get_property(np, "fsl,cpm-brg", &len); if (!data || len != 4) { - printk(KERN_ERR "CPM UART %pOFn has no/invalid " + dev_err(port->dev, "CPM UART %pOFn has no/invalid " "fsl,cpm-brg property.\n", np); return -EINVAL; } @@ -1164,7 +1164,7 @@ static int cpm_uart_init_port(struct device_node *np, data = of_get_property(np, "fsl,cpm-command", &len); if (!data || len != 4) { - printk(KERN_ERR "CPM UART %pOFn has no/invalid " + dev_err(port->dev, "CPM UART %pOFn has no/invalid " "fsl,cpm-command property.\n", np); return -EINVAL; } diff --git a/drivers/tty/serial/cpm_uart/cpm_uart_cpm2.c b/drivers/tty/serial/cpm_uart/cpm_uart_cpm2.c index 6a1cd03..ef1ae08 100644 --- a/drivers/tty/serial/cpm_uart/cpm_uart_cpm2.c +++ b/drivers/tty/serial/cpm_uart/cpm_uart_cpm2.c @@ -67,7 +67,7 @@ void __iomem *cpm_uart_map_pram(struct uart_cpm_port *port, return pram; if (len != 2) { - printk(KERN_WARNING "cpm_uart[%d]: device tree references " + dev_warn(port->dev, "cpm_uart[%d]: device tree references " "SMC pram, using boot loader/wrapper pram mapping. " "Please fix your device tree to reference the pram " "base register instead.\n", -- 1.9.1