From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.1 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,SIGNED_OFF_BY, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id AA4E4C388F7 for ; Tue, 3 Nov 2020 12:25:52 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 55DE022264 for ; Tue, 3 Nov 2020 12:25:52 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1604406352; bh=JnG9AEM3urtQJZbyh27ncRK5xtNjXhkMpT9pLY6ruAw=; h=References:In-Reply-To:From:Date:Subject:To:Cc:List-ID:From; b=nxHmIJ+xv8olXu3V/izhqmhaMSBBeHNwRI6cGk1CSZ4lqM8bVe2QGzYFQfhrbP6K5 nIGklJ93ofthaumnM4OfZ1lnXe02+67dgw1SRCPUUiuOiv3f16pxGiFbchc4Le5AQK 4OT+X68tMMCXl4a03/UK9auomkYaHrVmheGxn/V8= Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728993AbgKCMZr (ORCPT ); Tue, 3 Nov 2020 07:25:47 -0500 Received: from mail.kernel.org ([198.145.29.99]:40634 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728168AbgKCMZq (ORCPT ); Tue, 3 Nov 2020 07:25:46 -0500 Received: from mail-wr1-f50.google.com (mail-wr1-f50.google.com [209.85.221.50]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 0EAE822403; Tue, 3 Nov 2020 12:25:45 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1604406345; bh=JnG9AEM3urtQJZbyh27ncRK5xtNjXhkMpT9pLY6ruAw=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=S3ilUxfLmh/0Pv4skyGqFEAG0vwDSS5i5psimoXmAELMEWHSH2fW4IuM4Z+qMebRf WAXWrrJnkn0me0BHoC6LmAQbdfefgrg1IUndUDBw+RKZdCT9Ym0K7hlLMGCU1lFFO3 Zsx6vPAhW90E/61D8322HI52wvm4X0FuC5QxUJR0= Received: by mail-wr1-f50.google.com with SMTP id k10so17011011wrw.13; Tue, 03 Nov 2020 04:25:44 -0800 (PST) X-Gm-Message-State: AOAM531fAqcyHHSv2U9CZ9dP3oPogr0zh4cTugMzh94Ysy/X6sIGtfQM XykDjgWFCFOGJqS5maLpA0+4zpavr1VWgO7H7Fg= X-Google-Smtp-Source: ABdhPJzaMTU0V4sDEP7WFi1D19pueRl5ySNY/GA/QmiGvW8mi19ZpCI6gDmcGIwe2rHXpOPoRB6cN5TL6gD3Vvt/QEU= X-Received: by 2002:adf:eb4f:: with SMTP id u15mr19654094wrn.165.1604406343518; Tue, 03 Nov 2020 04:25:43 -0800 (PST) MIME-Version: 1.0 References: <20201103092712.714480842@linutronix.de> <20201103095857.078043987@linutronix.de> In-Reply-To: <20201103095857.078043987@linutronix.de> From: Arnd Bergmann Date: Tue, 3 Nov 2020 13:25:27 +0100 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [patch V3 05/37] asm-generic: Provide kmap_size.h To: Thomas Gleixner Cc: LKML , Linus Torvalds , Peter Zijlstra , Paul McKenney , Christoph Hellwig , Sebastian Andrzej Siewior , Andrew Morton , Linux-MM , Alexander Viro , Benjamin LaHaise , Linux FS-devel Mailing List , linux-aio , Chris Mason , Josef Bacik , David Sterba , linux-btrfs , "the arch/x86 maintainers" , Vineet Gupta , "open list:SYNOPSYS ARC ARCHITECTURE" , Russell King , Arnd Bergmann , Linux ARM , linux-csky@vger.kernel.org, Michal Simek , Thomas Bogendoerfer , "open list:BROADCOM NVRAM DRIVER" , Nick Hu , Greentime Hu , Vincent Chen , Michael Ellerman , Benjamin Herrenschmidt , Paul Mackerras , linuxppc-dev , "David S. Miller" , sparclinux , Chris Zankel , Max Filippov , linux-xtensa@linux-xtensa.org, Ingo Molnar , Juri Lelli , Vincent Guittot , Dietmar Eggemann , Steven Rostedt , Ben Segall , Mel Gorman , Daniel Bristot de Oliveira , Christian Koenig , Huang Rui , David Airlie , Daniel Vetter , dri-devel , VMware Graphics , Roland Scheidegger , Dave Airlie , Gerd Hoffmann , virtualization@lists.linux-foundation.org, spice-devel@lists.freedesktop.org, Ben Skeggs , ML nouveau , Jani Nikula , Joonas Lahtinen , Rodrigo Vivi , Intel Graphics Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-fsdevel@vger.kernel.org On Tue, Nov 3, 2020 at 10:27 AM Thomas Gleixner wrote: > > kmap_types.h is a misnomer because the old atomic MAP based array does not > exist anymore and the whole indirection of architectures including > kmap_types.h is inconinstent and does not allow to provide guard page > debugging for this misfeature. > > Add a common header file which defines the mapping stack size for all > architectures. Will be used when converting architectures over to a > generic kmap_local/atomic implementation. > > The array size is chosen with the following constraints in mind: > > - The deepest nest level in one context is 3 according to code > inspection. > > - The worst case nesting for the upcoming reemptible version would be: > > 2 maps in task context and a fault inside > 2 maps in the fault handler > 3 maps in softirq > 2 maps in interrupt > > So a total of 16 is sufficient and probably overestimated. > > Signed-off-by: Thomas Gleixner Acked-by: Arnd Bergmann