Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp4649674pxk; Wed, 30 Sep 2020 08:17:11 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzWkcT3zXfpZKroeQIY/AB9ymESsWhlqOH8eWCcAFsqOz/bQrsnlAGGL5nPWmRVKOqAksBD X-Received: by 2002:a50:f102:: with SMTP id w2mr3375942edl.63.1601479030840; Wed, 30 Sep 2020 08:17:10 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1601479030; cv=none; d=google.com; s=arc-20160816; b=VH7eYr0oVJ4AUIhjfLH88IDqecEYG4wrVDtkL/pQ4FQM68/+9CC75AM/nOZjWEGz9n onqPduTabzdTjPzShOnBe2gSNUknuAp7auwSots2cl0gBEtS4A/Rezg4VceXUQ+1U7qG tRF4p5HixYOklmEVEWhCZ3fiDaD71GOMSV+s8KQb2YMVq3DQy/4wud4U/eR7ZRwFyGNe q/nFK0kc8u+CmjuMMTLaZ0QGfpUdn1Ebls/CpadhA2pi+QAZml4BHtnxX5eEi3mIl6Ke n2jcKqraexzVAn6/l1yd5R9MBSQEzQ/sZMFdH0kSJvnXf9EiuLDsEKp+/YieAHm9W7PP 3COA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:subject:cc:to:from:date :dkim-signature; bh=y+6s7uptRWxSL+Isb3ZuSOkp2qVKA7pziOiGTor99Nw=; b=WT6I9AT2gNeSLcf+dXjpBeFUaDUb5sWLH2c5KikHaaH7xrjpRmvZPccK2lc0adv629 ROQ5qlDSzFhapWARGI8TgxTCdv1TsKqxRZf/EQkXvi7xXcWWL9RiQPoDZTXqfCec/iIg zaL7gImvixi4VymExCCSRlWKby2iRTeY6cg3ny9SssiYkdfCwdr8lyZ+qhRME/noVejz q0GHu67URij64zJaaETbJmyY8OK+kWvFx3bGpySqX/+onrCWcqcN50XdDU0m2NjPEqOR c6zKzie9ztK0EsxKe9sjpUD94is4BZ69SSQ4OmCXwp4pohtw0zZqAaGrPJSn91XXWAW3 MorA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=zSART5+V; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id u12si1277980edy.390.2020.09.30.08.16.46; Wed, 30 Sep 2020 08:17:10 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=zSART5+V; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730791AbgI3PNf (ORCPT + 99 others); Wed, 30 Sep 2020 11:13:35 -0400 Received: from mail.kernel.org ([198.145.29.99]:37642 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725823AbgI3PNc (ORCPT ); Wed, 30 Sep 2020 11:13:32 -0400 Received: from coco.lan (ip5f5ad5c4.dynamic.kabel-deutschland.de [95.90.213.196]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 90CAE20657; Wed, 30 Sep 2020 15:13:30 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1601478811; bh=tu8ftrC/0bjq3PeLZIRfKTlpvOojwl1EwbHoEDNIvgQ=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=zSART5+VxnaxSywTcYKJlwI5Q7jOjrzdig/Ri5UB6XV0cGLTo/PQ2wQ3Pvkfu5Q8N WxHXppc1DC+2Z7ZSlyG5UFS6o/AU24cfIcuz7+wKywKwaRNQIumKEV2w9trVeEK90V uxQ+K2wn3gRH32bIrLWXe6E0ItLA8gLyEEQiI05Q= Date: Wed, 30 Sep 2020 17:13:27 +0200 From: Mauro Carvalho Chehab To: Mike Rapoport Cc: Linux Doc Mailing List , Jonathan Corbet , Andrew Morton , linux-kernel@vger.kernel.org, linux-mm@kvack.org Subject: Re: [PATCH v4 19/52] memblock: get rid of a :c:type leftover Message-ID: <20200930171327.509ee344@coco.lan> In-Reply-To: <20200930142323.GL2142832@kernel.org> References: <0aab04f62bc3dfa82394e20d61c05c6efbfb4859.1601467849.git.mchehab+huawei@kernel.org> <20200930142323.GL2142832@kernel.org> X-Mailer: Claws Mail 3.17.6 (GTK+ 2.24.32; x86_64-redhat-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Em Wed, 30 Sep 2020 17:23:23 +0300 Mike Rapoport escreveu: > Hello Mauro, > > On Wed, Sep 30, 2020 at 03:24:42PM +0200, Mauro Carvalho Chehab wrote: > > chanseset b3a7bb1851c8 ("docs: get rid of :c:type explicit declarations for structs") > > removed several :c:type: markups, except by one. > > > > Now, Sphinx 3.x complains about it: > > > > .../Documentation/core-api/boot-time-mm:26: ../mm/memblock.c:51: WARNING: Unparseable C cross-reference: 'struct\nmemblock_type' > > Invalid C declaration: Expected identifier in nested name, got keyword: struct [error at 6] > > struct > > memblock_type > > ------^ > > Maybe this warning is caused by '\n' between struct and memblock_type? > There are two more occurences of :c:type: around and they do not seem to > cause warnings. Yeah, maybe. Yet, according with: https://www.sphinx-doc.org/en/master/usage/restructuredtext/domains.html#c-roles c:type: should only be used together with ".. c:type", and this doesn't work anymore for declaring structs, as the only valid ways of using it after Sphinx 3.0 are: .. c:type:: typedef-like declaration .. c:type:: name So, the old syntax generated by kernel doc: .. c:type:: struct foo Doesn't work anymore. Kernel-doc now uses, instead: .. c:struct:: foo (if version >= 3.0) So, the right tag would be: :c:struct`foo`, if Sphinx > 3 or c:type:`foo` for older versions. Better to rely on having the automarkup solving this for us. - > > > As, on Sphinx 3.x, the right markup is c:struct:`foo`. > > > > So, let's remove it, relying on automarkup.py to convert it. > > > > Signed-off-by: Mauro Carvalho Chehab > > --- > > mm/memblock.c | 4 ++-- > > 1 file changed, 2 insertions(+), 2 deletions(-) > > > > diff --git a/mm/memblock.c b/mm/memblock.c > > index 165f40a8a254..326c6b3fec1d 100644 > > --- a/mm/memblock.c > > +++ b/mm/memblock.c > > @@ -50,8 +50,8 @@ > > * > > * Each region is represented by :c:type:`struct memblock_region` that > > Can you please also convert this one? > > > * defines the region extents, its attributes and NUMA node id on NUMA > > - * systems. Every memory type is described by the :c:type:`struct > > - * memblock_type` which contains an array of memory regions along with > > + * systems. Every memory type is described by the struct memblock_type > > + * which contains an array of memory regions along with > > * the allocator metadata. The "memory" and "reserved" types are nicely > > * wrapped with :c:type:`struct memblock`. This structure is statically > > And this? Good point. I'll change those too for the next version. > > > * initialized at build time. The region arrays are initially sized to > > -- > > 2.26.2 > > > Thanks, Mauro