From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752802Ab3JALb3 (ORCPT ); Tue, 1 Oct 2013 07:31:29 -0400 Received: from mga01.intel.com ([192.55.52.88]:3310 "EHLO mga01.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751173Ab3JALb2 (ORCPT ); Tue, 1 Oct 2013 07:31:28 -0400 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="4.90,1013,1371106800"; d="scan'208";a="403604922" Date: Tue, 1 Oct 2013 19:31:15 +0800 From: Fengguang Wu To: Greg Kroah-Hartman Cc: Alexander Shiyan , kbuild-all@01.org, linux-kernel@vger.kernel.org Subject: [PATCH] serial: sccnxp: replace memcpy with struct assignment Message-ID: <20131001113115.GB5525@localhost> References: <5244e22f.VLBQtuO7RvNh9dWF%fengguang.wu@intel.com> <20131001020847.GA9317@kroah.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20131001020847.GA9317@kroah.com> User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Generated by: coccinelle/misc/memcpy-assign.cocci CC: Alexander Shiyan Signed-off-by: Fengguang Wu --- drivers/tty/serial/sccnxp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- linux-next.orig/drivers/tty/serial/sccnxp.c 2013-10-01 19:27:55.057537955 +0800 +++ linux-next/drivers/tty/serial/sccnxp.c 2013-10-01 19:28:17.873536923 +0800 @@ -907,7 +907,7 @@ static int sccnxp_probe(struct platform_ } if (pdata) - memcpy(&s->pdata, pdata, sizeof(struct sccnxp_pdata)); + s->pdata = *pdata; if (s->pdata.poll_time_us) { dev_info(&pdev->dev, "Using poll mode, resolution %u usecs\n",