linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Michal Simek <michal.simek@xilinx.com>
To: linux-kernel@vger.kernel.org, monstr@monstr.eu,
	gnomes@lxorguk.ukuu.org.uk, Alexander Graf <agraf@suse.de>,
	shubhraj@xilinx.com, robh@kernel.org
Cc: Jiri Slaby <jslaby@suse.com>,
	linux-serial@vger.kernel.org,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	linux-arm-kernel@lists.infradead.org
Subject: [PATCH v3 02/10] serial: uartps: Do not initialize field to zero again
Date: Mon,  3 Sep 2018 15:10:50 +0200	[thread overview]
Message-ID: <bf45db771f1f4b5bf9a006c3a1d8016bebc53df1.1535980253.git.michal.simek@xilinx.com> (raw)
In-Reply-To: <cover.1535980253.git.michal.simek@xilinx.com>
In-Reply-To: <cover.1535980253.git.michal.simek@xilinx.com>

Writing zero and NULLs to already initialized fields is not needed.
Remove this additional writes.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
---

Changes in v3: None
Changes in v2:
- new patch - it can be sent separately too

 drivers/tty/serial/xilinx_uartps.c | 3 ---
 1 file changed, 3 deletions(-)

diff --git a/drivers/tty/serial/xilinx_uartps.c b/drivers/tty/serial/xilinx_uartps.c
index dd905c981f67..9a08542cec47 100644
--- a/drivers/tty/serial/xilinx_uartps.c
+++ b/drivers/tty/serial/xilinx_uartps.c
@@ -1502,15 +1502,12 @@ static int cdns_uart_probe(struct platform_device *pdev)
 
 	/* At this point, we've got an empty uart_port struct, initialize it */
 	spin_lock_init(&port->lock);
-	port->membase	= NULL;
-	port->irq	= 0;
 	port->type	= PORT_UNKNOWN;
 	port->iotype	= UPIO_MEM32;
 	port->flags	= UPF_BOOT_AUTOCONF;
 	port->ops	= &cdns_uart_ops;
 	port->fifosize	= CDNS_UART_FIFO_SIZE;
 	port->line	= id;
-	port->dev	= NULL;
 
 	/*
 	 * Register the port.
-- 
1.9.1


  parent reply	other threads:[~2018-09-03 13:11 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-09-03 13:10 [PATCH v3 00/10] serial: uartps: Add run time support for more IPs than hardcoded 2 Michal Simek
2018-09-03 13:10 ` [PATCH v3 01/10] serial: uartps: console_setup() can't be placed to init section Michal Simek
2018-09-03 13:10 ` Michal Simek [this message]
2018-09-03 13:10 ` [PATCH v3 03/10] serial: uartps: Fix suspend functionality Michal Simek
2018-09-03 13:10 ` [PATCH v3 04/10] serial: uartps: Do not use static struct uart_driver out of probe() Michal Simek
2018-09-03 13:10 ` [PATCH v3 05/10] serial: uartps: Move alias reading higher in probe() Michal Simek
2018-09-03 13:10 ` [PATCH v3 06/10] serial: uartps: Move register to probe based on run time detection Michal Simek
2018-09-03 13:10 ` [PATCH v3 07/10] serial: uartps: Fill struct uart_driver in probe() Michal Simek
2018-09-03 13:10 ` [PATCH v3 08/10] serial: uartps: Change logic how console_port is setup Michal Simek
2018-09-03 13:10 ` [PATCH v3 09/10] serial: uartps: Register own uart console and driver structures Michal Simek
2018-09-03 13:10 ` [PATCH v3 10/10] serial: uartps: Move Port ID to device data structure Michal Simek
2018-09-18 11:54 ` [PATCH v3 00/10] serial: uartps: Add run time support for more IPs than hardcoded 2 Michal Simek
2018-09-18 12:01   ` Greg Kroah-Hartman

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=bf45db771f1f4b5bf9a006c3a1d8016bebc53df1.1535980253.git.michal.simek@xilinx.com \
    --to=michal.simek@xilinx.com \
    --cc=agraf@suse.de \
    --cc=gnomes@lxorguk.ukuu.org.uk \
    --cc=gregkh@linuxfoundation.org \
    --cc=jslaby@suse.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-serial@vger.kernel.org \
    --cc=monstr@monstr.eu \
    --cc=robh@kernel.org \
    --cc=shubhraj@xilinx.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).