Received: by 2002:ac0:a594:0:0:0:0:0 with SMTP id m20-v6csp2931837imm; Thu, 17 May 2018 00:00:00 -0700 (PDT) X-Google-Smtp-Source: AB8JxZoI9Jg1fcLo4XvZu2/JrXXw0Y0Pj0jNLEf6/og2uVuMedPBbAtl18Qo/rFxGqGG0AyU6MZ/ X-Received: by 2002:a62:bd18:: with SMTP id a24-v6mr4007814pff.30.1526540400487; Thu, 17 May 2018 00:00:00 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1526540400; cv=none; d=google.com; s=arc-20160816; b=k8r1olwtwwMK8QAszGeQbrbDyEQ0rDlUYrUcs9/Od+VdCEqTvmMgN5qGTWrHp57nUa UHkZuNnry/cnfGZvXXOEl2gHhEp/HadZt0BYJ1LLRAk0w261GwcMIr6IdrABR4sL4AdE 0ccGUsq9ebc2bQyChIhNQXUELnZTt273Gi5POrkWl5uKy1IKHdhlYoyaaoRxnUfX/jKT 3tKS9fwe47S9u/K0Jnlv7MgpARJYKMACCyEGt40VeqJ+RrJPtQ7I2z7m9vxOTj3q2tpQ SCcJLwsVaIDrToeO8y9Kem4kTst4ejIEnDd1/S+8y/ju+HqxuKiJZf/UOViIXGm2lfSY baJw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :references:in-reply-to:mime-version:dkim-signature :arc-authentication-results; bh=9ol2phpFIG2rdGSdXCHy7li9oagf807zNKYbIuRaZK8=; b=inxMWJ3csi/CAzKtPu0XeV/wR1PZ1OjU1wcfK/h1fAoGTj6OlHVjkfNUXjXjuDFze3 bAKzXEsa81r2foG/nCityghDlT0kOo186tYWC9wg+5qYgWLj+GD224WUb74pXRDHu5rG EEDLwOWBXMjb3LoyvQ9aD9vrakWDQkmuTzlFdgpoE/LdgKGOPJg25URjHOI0gZIQDT0z s46bSXydu4yUli9kQJc/W5egeLTr02ekZTcnFw9pRsaGBOeb09jWuGTymK2z8ovQF6wz 2ei4kPu1bctTZZ+4QsGERofYkqKn2cBz951ZdqNciVSC/17JPKtH+WELy1SYaQeLJtXz RvgA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=NUdbarln; 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; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id v64-v6si3537474pgv.528.2018.05.16.23.59.46; Thu, 17 May 2018 00:00:00 -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; dkim=pass header.i=@gmail.com header.s=20161025 header.b=NUdbarln; 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; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751999AbeEQG7f (ORCPT + 99 others); Thu, 17 May 2018 02:59:35 -0400 Received: from mail-ua0-f196.google.com ([209.85.217.196]:41624 "EHLO mail-ua0-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751293AbeEQG7e (ORCPT ); Thu, 17 May 2018 02:59:34 -0400 Received: by mail-ua0-f196.google.com with SMTP id a3-v6so2240248uad.8 for ; Wed, 16 May 2018 23:59:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=9ol2phpFIG2rdGSdXCHy7li9oagf807zNKYbIuRaZK8=; b=NUdbarlnlCyhAXNa7E1/Q95MeVdQl4xwKwL99BBeyGxan9IEAyuEm72UnhxaKOlA05 w/pp/Oe1P1sR1BJ/uWP3kQgILq/F1nkAzheCDrmBepl4QuJRFj47SN6UD8W9vT/+aF8R mbnxCMKyYGQviDXkGYpErBln5f0ZeZ1QfFwrbEqn/XsuqFsEl4exFUAA6F15sNCgFbyI b2B73Fu8LGCgOJXuLFkZkavd/+MgSBjkyLry1hHxbAs95b5V7k8lA0R540aPQvQXVKGm tVisqPNYlKsnppYJtBkBC/ZqxtUwhXtwJuanOCJGSshHsmYRaQqPE9aHblAbVGCzbR3r c3ew== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=9ol2phpFIG2rdGSdXCHy7li9oagf807zNKYbIuRaZK8=; b=LG/x4A3M2gRJxZc4McgQxnc3FkQ8/4N/jfsw4NpZEGJZg+l86tzpmAoF6+K6DNuqM3 GrQwS5wAo+5qu8Pp/ys+U1TWNuDaOPDlWaw3bs421QPJc0OdWvOFV3ahMs6UHh8f6Mqm HMdQrlEGR9Hd6vTdKQ19efE6Zgks7XLs2gVydq1nlte7EptfCJ50+P93tXA1nw+SDlcM EXdjwnkQTPd3E/13+w8YYY+cqeoiu7KpnDgWgvsr2ZQBoSFuySWSrJETEE5Kte6EDOTh 7BU9eNPmZXiK3qXF7KZIdL4vbkThK1MysGc03q1NdVGkLW7zNWehHINAe9hBITUMkB3V Kgfw== X-Gm-Message-State: ALKqPwekurVTBkX/PdN10KebHr2jG0PbfXcbjao54GEBb/amsafOC5Yq ZuZxPDWyslE0viV+yccK4Y2QSMvGH5mrvqTMQaw= X-Received: by 2002:a9f:3606:: with SMTP id r6-v6mr3597474uad.49.1526540373394; Wed, 16 May 2018 23:59:33 -0700 (PDT) MIME-Version: 1.0 Received: by 10.176.92.86 with HTTP; Wed, 16 May 2018 23:58:53 -0700 (PDT) In-Reply-To: <1526373963-12417-1-git-send-email-vincentc@andestech.com> References: <1526373963-12417-1-git-send-email-vincentc@andestech.com> From: Greentime Hu Date: Thu, 17 May 2018 14:58:53 +0800 Message-ID: Subject: Re: [PATCH 0/3]nds32: Correct the cache operation for catch aliasing case To: Vincent Chen Cc: Linux Kernel Mailing List , Greentime , Arnd Bergmann , Vincent Chen Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 2018-05-15 16:46 GMT+08:00 Vincent Chen : > The following 3 issues are fixed in this patchset > > 1. In function flush_dacache_page and copy_user_highpage, the local irq is > enabled when the cache of the page at address page_address(page) is written > back to memory. It possibly causes data corruption. To fix this problem, > the local irq is disabled before executing d-cache write-back and > invalidate in this patchset. > > 2. According to Documentation/cachetlb.txt, the cache of the page at vmaddr > shall be flushed in flush_anon_page instead of the cache of the page at > page_address(page). We correct it and add the modification to this > patchset. > > 3. Removing unneeded cache invalidation in copy_user_highpage function. > > > Vincent Chen (3): > nds32: Correct flush_dcache_page function > nds32: Flush the cache of the page at vmaddr instead of kaddr in > flush_anon_page > nds32: Disable local irq before calling cpu_dcache_wb_page in > copy_user_highpage > > arch/nds32/mm/cacheflush.c | 34 ++++++++++++++++++++-------------- > 1 files changed, 20 insertions(+), 14 deletions(-) > Thank you, Vincent. Reviewed-by: Greentime Hu