Received: by 2002:a5b:505:0:0:0:0:0 with SMTP id o5csp5253821ybp; Mon, 7 Oct 2019 23:15:45 -0700 (PDT) X-Google-Smtp-Source: APXvYqypQ5EFY3uYoBupDFvPqTQbrgXz0jfTtc8fQyCgDQQVOPzzixpFbbuNO+SkkQrbaoKcLWcQ X-Received: by 2002:aa7:d9d5:: with SMTP id v21mr31979590eds.106.1570515345565; Mon, 07 Oct 2019 23:15:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1570515345; cv=none; d=google.com; s=arc-20160816; b=kJD47bQF6L9Ry6mqHhHFJ3PsNX8E3DpTmVb9lKsq0DxMplW8IRLu1/ZP0CmovRUMZo xFjkWcajgn9u7GSLQsLXv1Nruf9T/J44Lu+HUeUmnbsVLfZf0nfSH8kTdD/e3/SERCWo N/OWdmA45ahWSvoM6P2dImadPPUbHUDWNr+5DFfSbVNEByrApQAztwANjNPPewaO1hlG QGUuV2Ylp/Bd4lLqVe1VhknxK/ntJ6wIA8yyR/+fI2i3DfR5tL6ZG1/iQfu5NQd4178o VI2dqeyX7XdbAvWeWeTe788jaiAl1F4dLJ0C7Yiubyu75rH0sTJZvPQEl+LaTVsPM2s+ U5tw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from; bh=f+V57mIuxcU3eo1NssNNzU+w/awJb4VMkV0TFNU8Cyc=; b=KYHXJ8c6mHnBGJ1c49D88q3P5FXLelyzOGYrNTO6hAByCcuXMqTcUoNNpZycAPXl+X quRmscfMjOPN9ldoZBP40IgRtSCFahvi6rnPOOpT+n6vSjrfAz/31POPjzSwyreLaosa VKtTNYBjH/oBbcKZysWGsa5l0OPna9Fh7eT3YwgZJq3CvbXzmQV/dIzjc3zABZ8oC03j ZxJNmQ/o4BBAkACGAgri1SI8Pd8j89GJRkCH7+ctRIPNHtzH0yoErE1XxxZ7WUAZtww9 DGl6EkdESmV51swayBzRPUFbaJnLj5j0c4sDXcGhuta6XUkkVpM/J48qaOJXQHYHefaC TU0Q== 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 b15si9925336edm.395.2019.10.07.23.15.21; Mon, 07 Oct 2019 23:15:45 -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 S1730083AbfJHGNw (ORCPT + 99 others); Tue, 8 Oct 2019 02:13:52 -0400 Received: from 59-120-53-16.HINET-IP.hinet.net ([59.120.53.16]:28978 "EHLO ATCSQR.andestech.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1730038AbfJHGNn (ORCPT ); Tue, 8 Oct 2019 02:13:43 -0400 Received: from mail.andestech.com (atcpcs16.andestech.com [10.0.1.222]) by ATCSQR.andestech.com with ESMTP id x985uHCM075309; Tue, 8 Oct 2019 13:56:17 +0800 (GMT-8) (envelope-from nickhu@andestech.com) Received: from atcsqa06.andestech.com (10.0.15.65) by ATCPCS16.andestech.com (10.0.1.222) with Microsoft SMTP Server id 14.3.123.3; Tue, 8 Oct 2019 14:12:08 +0800 From: Nick Hu To: , , , , , , , , , , , , , , , , , , , CC: Nick Hu Subject: [PATCH v3 1/3] kasan: Archs don't check memmove if not support it. Date: Tue, 8 Oct 2019 14:11:51 +0800 Message-ID: X-Mailer: git-send-email 2.17.0 In-Reply-To: References: MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [10.0.15.65] X-DNSRBL: X-MAIL: ATCSQR.andestech.com x985uHCM075309 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Skip the memmove checking for those archs who don't support it. Signed-off-by: Nick Hu --- mm/kasan/common.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/mm/kasan/common.c b/mm/kasan/common.c index 6814d6d6a023..897f9520bab3 100644 --- a/mm/kasan/common.c +++ b/mm/kasan/common.c @@ -107,6 +107,7 @@ void *memset(void *addr, int c, size_t len) return __memset(addr, c, len); } +#ifdef __HAVE_ARCH_MEMMOVE #undef memmove void *memmove(void *dest, const void *src, size_t len) { @@ -115,6 +116,7 @@ void *memmove(void *dest, const void *src, size_t len) return __memmove(dest, src, len); } +#endif #undef memcpy void *memcpy(void *dest, const void *src, size_t len) -- 2.17.0