From patchwork Wed Apr 23 14:58:36 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Felipe Balbi X-Patchwork-Id: 28899 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-ve0-f198.google.com (mail-ve0-f198.google.com [209.85.128.198]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id A000E203AC for ; Wed, 23 Apr 2014 15:01:36 +0000 (UTC) Received: by mail-ve0-f198.google.com with SMTP id oz11sf4137924veb.5 for ; Wed, 23 Apr 2014 08:01:36 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:delivered-to:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:sender:precedence:list-id :x-original-sender:x-original-authentication-results:mailing-list :list-post:list-help:list-archive:list-unsubscribe:content-type; bh=B+RpQNNcY2+QC4Ne3r6RgxGhVIDO220es44/7RH8IkU=; b=i/RTZNeMtXsJkvqfQsrhVCBneasC0VhIRS76jHxT/sHXMxRirWpqBXc7jmTUwVpVKQ qKG1eAJAmqOKqek968MWawzxR0DDAg9E+v3FSdr13qXU1g7vpz6h9EzNWI6IMiqgumRf EGkI08zjR4Tscl3wRME5eO4hbR6V3kqgujX0gZFXehWpDDG1LNGL0Qs71T2sttDFMTAm j7I3ny/TbknVgd5543Gt2D6n6g/WNioNGlYFb07RcMyi1OGCh+sjfOIscv9LmNMCrWXW EM53ZhlSGF8jrtV8hBMUPQWL/VZUIJTK4pFyIUPUUmR/S43LxqNrtOh93bw+AmEHDIlT yuyA== X-Gm-Message-State: ALoCoQk5EVefEvtKdxjjCKWmGkRHIPeu6q+65an3KkQyzkIEdD5Mv9O9NaVyV/+2FgLJB9QDPcJi X-Received: by 10.58.41.39 with SMTP id c7mr27027793vel.25.1398265296402; Wed, 23 Apr 2014 08:01:36 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.140.27.38 with SMTP id 35ls633999qgw.77.gmail; Wed, 23 Apr 2014 08:01:36 -0700 (PDT) X-Received: by 10.58.200.227 with SMTP id jv3mr400023vec.77.1398265296220; Wed, 23 Apr 2014 08:01:36 -0700 (PDT) Received: from mail-ve0-f179.google.com (mail-ve0-f179.google.com [209.85.128.179]) by mx.google.com with ESMTPS id sn5si208116vdc.191.2014.04.23.08.01.36 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Wed, 23 Apr 2014 08:01:36 -0700 (PDT) Received-SPF: none (google.com: patch+caf_=patchwork-forward=linaro.org@linaro.org does not designate permitted sender hosts) client-ip=209.85.128.179; Received: by mail-ve0-f179.google.com with SMTP id db12so1312047veb.10 for ; Wed, 23 Apr 2014 08:01:36 -0700 (PDT) X-Received: by 10.221.26.10 with SMTP id rk10mr43000232vcb.0.1398265295661; Wed, 23 Apr 2014 08:01:35 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.220.221.72 with SMTP id ib8csp110606vcb; Wed, 23 Apr 2014 08:01:35 -0700 (PDT) X-Received: by 10.50.66.203 with SMTP id h11mr3073992igt.49.1398265295089; Wed, 23 Apr 2014 08:01:35 -0700 (PDT) Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id pn4si757791pac.421.2014.04.23.08.01.34; Wed, 23 Apr 2014 08:01:34 -0700 (PDT) Received-SPF: none (google.com: linux-kernel-owner@vger.kernel.org does not designate permitted sender hosts) client-ip=209.132.180.67; Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757418AbaDWPB0 (ORCPT + 27 others); Wed, 23 Apr 2014 11:01:26 -0400 Received: from arroyo.ext.ti.com ([192.94.94.40]:32906 "EHLO arroyo.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753686AbaDWPBT (ORCPT ); Wed, 23 Apr 2014 11:01:19 -0400 Received: from dflxv15.itg.ti.com ([128.247.5.124]) by arroyo.ext.ti.com (8.13.7/8.13.7) with ESMTP id s3NF1BjP005010; Wed, 23 Apr 2014 10:01:11 -0500 Received: from DFLE73.ent.ti.com (dfle73.ent.ti.com [128.247.5.110]) by dflxv15.itg.ti.com (8.14.3/8.13.8) with ESMTP id s3NF1B4a021553; Wed, 23 Apr 2014 10:01:11 -0500 Received: from dflp33.itg.ti.com (10.64.6.16) by DFLE73.ent.ti.com (128.247.5.110) with Microsoft SMTP Server id 14.3.174.1; Wed, 23 Apr 2014 10:01:10 -0500 Received: from localhost (ileax41-snat.itg.ti.com [10.172.224.153]) by dflp33.itg.ti.com (8.14.3/8.13.8) with ESMTP id s3NF1AjI027958; Wed, 23 Apr 2014 10:01:11 -0500 From: Felipe Balbi To: Greg KH CC: , , , , , Linux Kernel Mailing List , , , , Linux OMAP Mailing List , Tony Lindgren , Felipe Balbi Subject: [PATCH 12/13] tty: serial: omap: fix Sparse warnings Date: Wed, 23 Apr 2014 09:58:36 -0500 Message-ID: <1398265117-11793-12-git-send-email-balbi@ti.com> X-Mailer: git-send-email 1.9.2.459.g68773ac In-Reply-To: <1398265117-11793-1-git-send-email-balbi@ti.com> References: <1398265117-11793-1-git-send-email-balbi@ti.com> MIME-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org Precedence: list List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: balbi@ti.com X-Original-Authentication-Results: mx.google.com; spf=neutral (google.com: patch+caf_=patchwork-forward=linaro.org@linaro.org does not designate permitted sender hosts) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , Fix the following Sparse warnings: drivers/tty/serial/omap-serial.c:1418:49: warning: incorrect \ type in argument 2 (different address spaces) drivers/tty/serial/omap-serial.c:1418:49: expected void const \ [noderef] *from drivers/tty/serial/omap-serial.c:1418:49: got struct serial_rs485 \ * drivers/tty/serial/omap-serial.c:1426:35: warning: incorrect \ type in argument 1 (different address spaces) drivers/tty/serial/omap-serial.c:1426:35: expected void [noderef] \ *to drivers/tty/serial/omap-serial.c:1426:35: got struct serial_rs485 \ * Reported-by: Nishanth Menon Signed-off-by: Felipe Balbi --- drivers/tty/serial/omap-serial.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/tty/serial/omap-serial.c b/drivers/tty/serial/omap-serial.c index ab22dab..d017cec 100644 --- a/drivers/tty/serial/omap-serial.c +++ b/drivers/tty/serial/omap-serial.c @@ -1398,7 +1398,7 @@ serial_omap_ioctl(struct uart_port *port, unsigned int cmd, unsigned long arg) switch (cmd) { case TIOCSRS485: - if (copy_from_user(&rs485conf, (struct serial_rs485 *) arg, + if (copy_from_user(&rs485conf, (void __user *) arg, sizeof(rs485conf))) return -EFAULT; @@ -1406,7 +1406,7 @@ serial_omap_ioctl(struct uart_port *port, unsigned int cmd, unsigned long arg) break; case TIOCGRS485: - if (copy_to_user((struct serial_rs485 *) arg, + if (copy_to_user((void __user *) arg, &(to_uart_omap_port(port)->rs485), sizeof(rs485conf))) return -EFAULT;