Received: by 2002:a25:ab43:0:0:0:0:0 with SMTP id u61csp38804ybi; Thu, 23 May 2019 23:09:25 -0700 (PDT) X-Google-Smtp-Source: APXvYqz2UM1xAwj1DSNc45TIpyueJzcWlbJQ6F45qyxJ0XG9xX5GtQtLph63OGcZHDzwy3BsvdTA X-Received: by 2002:a65:4144:: with SMTP id x4mr44718013pgp.282.1558678165507; Thu, 23 May 2019 23:09:25 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1558678165; cv=none; d=google.com; s=arc-20160816; b=bRI5CGYlMq/s7lk2ZT7fTQ1M6+8TsdJu+ipPLKYp/O/E46IpvqBDkxyfNtnuNdvnjp 9/9I5OdDRBD6akYogN0zG0O83gAGUUDc0Ndu5CrmmBCutWajPb2xMfQGI8FlI7HTrSnV 6kI/XpOs7CcHh+aNeVcotWUSVIvygrVDvKbRYN8ebicCSn1g+juDgha4PQCVvFzDydqS hEm/O7/ATXJ3Eeh6tIf+3jrq5nlf7X+1ieSQtwrNOUeSS3I7lmBVLQLcEwpEBvYoeHQh 8ibR+NtA2+cD5bWbB1FXafLHyt1g8ZkJseYwmGaUacfSWkdaPoDn93JT8ZJhYXGxdTVh wAyA== 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 :in-reply-to:references:mime-version:dkim-signature; bh=d6DjOHpSOGiAQtqaZSVvnSZsCuiDPmUFs7J2NpGe6Nc=; b=zQxZEg6Vnrcjtqtn3FL2W6EWsn07nRWiaMA6TYXIAlLVtynShcpaufQSiXHYTGz8v5 SvKb6Gjm+FD5ruhGnUTeFHdoov9M8KDbZU4ar8mKYQzzOCY/Q2YsDlC9FvlzyMgoFrBf +vjD5J+hpi3j64/tNVA+CwGo4IqqhEOaHB0nCTMWL67ZmecDFH1MP0qHUyMc8PHM3KTI J5H15CcruVXfe7wJn2WmQ/EjcCYRLNO7G/zjZp0T/w6gVgaUxgfo/qUum33Kv/7FCCjM HWrmpVALZ2OUzw1DgCkYaTLiRkvpagP/SShEctKOmAXqf7uLK6k75dtYlWopIIf953dR Ztdg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=nORqcTXC; 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 b9si2354070pjo.95.2019.05.23.23.09.04; Thu, 23 May 2019 23:09:25 -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=nORqcTXC; 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 S2388842AbfEXGHZ (ORCPT + 99 others); Fri, 24 May 2019 02:07:25 -0400 Received: from mail-lf1-f66.google.com ([209.85.167.66]:40066 "EHLO mail-lf1-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2387622AbfEXGHZ (ORCPT ); Fri, 24 May 2019 02:07:25 -0400 Received: by mail-lf1-f66.google.com with SMTP id h13so6160991lfc.7 for ; Thu, 23 May 2019 23:07:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=d6DjOHpSOGiAQtqaZSVvnSZsCuiDPmUFs7J2NpGe6Nc=; b=nORqcTXCVV9nc9SK2YQWhJtsGOqSZD23NIUbnDdDxpL15XGhtVHKX0MfppXOLJFBwy 0P9t6kFlbch9f1PPUI4mIvX4hzRrC9Dzyv2b5wI6YlnmSDo7a85L2k8G0y53pUO7qSSP tDnpGi4l+ev/I4v9YrPZJl0QFph7+OXMB3vpNBL3yk5sqQq0XXMerZ9VOfmBlTRfQlSF m9TLcHtU7IlfR4AEnuVAPxAQRy8z3P2g+DEOpRbEYUSI/n560HdYHlZGnjVhariXnLkm Q94mMO8WE4VXjnf4x40hg+tSoxGlTX0XCVnP7/Q/gthDC0x3mKFiLxIkemuMlfWtETFK N5Rw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=d6DjOHpSOGiAQtqaZSVvnSZsCuiDPmUFs7J2NpGe6Nc=; b=St0NfSuV0XPi3dNGPlHD0Z1Ex/F/RV+BfT72LPG6qfI9w+jt4GL4EZncAoPSdUmO1e eSgIkbEfY23absukVERaqYo4P2hhuPlUT+ZfvO9sFSaziEMTh8WAtj8JVWkPR1S7l3Gm chg61e5Cx4i2rWAMrrY6/8sgLf45cccKvTp5LVfELtGPJOmDDFl42RxyvOJ9+qvNzDUk oCgUyfk5GIq3H4rURgeny7Yh/jaIjIHbm9mm/UpJ3lSUmbIN8EiV5bjrPPa8yWr27pIR SNNqSsMrD05605lmVIXPb1XQx/4i3UPHtrpcmsfoWSJ96rko031VFWJe9HwhE5AZVxah GIhw== X-Gm-Message-State: APjAAAUbL9WvT0rYlyVT4vpqcV6+hMM0MoJxRLy5WlPXlDyFopV/+aY4 TYkoXH3MXc2As+WzoY5scURPvLuHUvovPJ+/BFQ= X-Received: by 2002:a05:6512:508:: with SMTP id o8mr7037970lfb.119.1558678043701; Thu, 23 May 2019 23:07:23 -0700 (PDT) MIME-Version: 1.0 References: <1558366258-3808-1-git-send-email-jrdr.linux@gmail.com> <20190521085547.58e1650c@erd987> In-Reply-To: From: Souptick Joarder Date: Fri, 24 May 2019 11:37:12 +0530 Message-ID: Subject: Re: [PATCH 2/2] auxdisplay/ht16k33.c: Convert to use vm_map_pages_zero() To: Miguel Ojeda Cc: Robin van der Gracht , linux-kernel , Matthew Wilcox 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 On Fri, May 24, 2019 at 9:52 AM Miguel Ojeda wrote: > > On Thu, May 23, 2019 at 2:58 PM Miguel Ojeda > wrote: > > > > Taking a quick look now, by the way, why does vm_map_pages_zero() (and > > __vm_map_pages() etc.) get a pointer to an array instead of a pointer > > to the first element? For this particular driver, one page is getting mapped into vma. But there are other places where a entire page array ( with more than one pages) mapped into vma. That's the reason to pass pointer to an array and do rest of the operations inside __vm_map_pages(). https://lkml.org/lkml/2019/3/18/1265 > > Also, in __vm_map_pages(), semantically w.r.t. to the comment, > shouldn't the first check test for equality too? (i.e. for vm_pgoff == > num)? (even if such case fails in the second test anyway). Sorry, didn't get it. Do you mean there should be a separate check for *vm_pgoff == num* ? > Cheers, > Miguel