Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753053AbcDCKgo (ORCPT ); Sun, 3 Apr 2016 06:36:44 -0400 Received: from mga14.intel.com ([192.55.52.115]:26545 "EHLO mga14.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752446AbcDCKgm (ORCPT ); Sun, 3 Apr 2016 06:36:42 -0400 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.24,436,1455004800"; d="scan'208";a="947046763" Date: Sun, 3 Apr 2016 18:36:08 +0800 From: kbuild test robot To: Tomas Winkler Cc: kbuild-all@01.org, gregkh@linuxfoundation.org, Ulf Hansson , Adrian Hunter , James Bottomley , "Martin K. Petersen" , Vinayak Holikatti , Christoph Hellwig , Yaniv Gardi , Joao Pinto , linux-mmc@vger.kernel.org, linux-scsi@vger.kernel.org, linux-kernel@vger.kernel.org, Tomas Winkler Subject: [PATCH] char: rpmb: fix memdup_user.cocci warnings Message-ID: <20160403103608.GA81675@xian.intel.com> References: <201604031822.7UBwspdK%fengguang.wu@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1459676572-29921-5-git-send-email-tomas.winkler@intel.com> User-Agent: Mutt/1.5.23 (2014-03-12) X-SA-Exim-Connect-IP: X-SA-Exim-Mail-From: fengguang.wu@intel.com X-SA-Exim-Scanned: No (on bee); SAEximRunCond expanded to false Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 681 Lines: 30 drivers/char/rpmb/cdev.c:94:13-20: WARNING opportunity for memdup_user Use memdup_user rather than duplicating its implementation This is a little bit restricted to reduce false positives Generated by: scripts/coccinelle/api/memdup_user.cocci CC: Tomas Winkler Signed-off-by: Fengguang Wu --- 0 files changed rule starting on line 17: position variables or mixed modifs interfere with comm_assoc isobool ( ( ( (unknown *to == NULL) >>> IS_ERR(rule starting on line 17:to) | !unknown *to >>> IS_ERR(rule starting on line 17:to) ) | (unknown *NULL == unknown *to) >>> IS_ERR(rule starting on line 17:to) ) || ...)