Received: by 2002:ab2:3319:0:b0:1ef:7a0f:c32d with SMTP id i25csp627192lqc; Fri, 8 Mar 2024 07:24:01 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCUvVkXXRKSqzZ9xvxVFEzUAy4yza7eh8KnKPCwLeJtwa8xIqp8DoNteZdb7y+kT93RT98o+4Y6b6GYy5ciodSeqgPrA2Ry/Efft35HJwA== X-Google-Smtp-Source: AGHT+IEiA9V5rE3GO4FFgtICYmV+oAoH2Sm0wrKE5A3nk2w2pdnq0GP/fzDVCN9JDn3sf8ayEuVj X-Received: by 2002:a0c:ff4a:0:b0:68f:69bb:4b97 with SMTP id y10-20020a0cff4a000000b0068f69bb4b97mr13465784qvt.24.1709911441749; Fri, 08 Mar 2024 07:24:01 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1709911441; cv=pass; d=google.com; s=arc-20160816; b=ptNdtcg2OSl9zo1RKEoXIFLPdQc5J/p3jyCTHa4vj/AqQmbhP4ZMPDbT96axJC5HCt ji+I+uP/AKo13FBulaptw9FXPbgEJ2S67swtOwZj9Y2aVw3QbYwPlFSL0eBAFe7f+RWN VvldoUYDk6ojxG0G5JJqbzVJm5/9c27e6F80kbVihyOGma+L+f3cwkmRpLI/bRwn4OE1 bFxBzuxj129xHAOrZPhYu1OXrv1cZQnfXETudbRAZNaxsGF8+mrhFzl5iwdRlUssLtLt 4oU7qT3GrUS1EmFKrwVvJ84kZnXlV5GWeHOFZg2nn3u8o9eHl2iSJszF+otEVkCuPxAF To6w== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:list-unsubscribe:list-subscribe :list-id:precedence:dkim-signature; bh=bcBcmCbNUNK8QMRYlD0suSpFuYeDhzgpUC/IVV9/I8w=; fh=AZc1TUFhMnY+nKLaBoEtZJrc6D4MSh1Rv3e1tSLicW0=; b=Qw1Oli5B3dTG0U8Nf07OV+aezLlIye5Cne+y0mgkIu3T5Oo4oOShql9sFryGKm8IRZ zWGynfeM12fqbHk9e9yvaWMEDM9Mn+72rTlZGPfE34eEgz3Hig0wUb6eG8s2/6gKPU5I +aq67tTxPo8JREAat/OhS2cELjEvQpdUq1GNf5Xm509XaU9BIaIMfzvJJ6N7EQOSynK3 A9TwQA+Fw9keLBL1S4Pofvo6/vvjAP/SAzwWQadRwilirvGXR8znl3m6eH638zTtVRJG P7mNioHlw/vrvV4l+VuQcB5Hl4MMWNvGB6pREIXhGaD3SIHaFw+V281Al5M5VePY6oxv d3Hw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=dZANEPlx; arc=pass (i=1 spf=pass spfdomain=gmail.com dkim=pass dkdomain=gmail.com dmarc=pass fromdomain=gmail.com); spf=pass (google.com: domain of linux-kernel+bounces-97224-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-97224-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [147.75.199.223]) by mx.google.com with ESMTPS id fn10-20020ad45d6a000000b0068f3602c8b9si20492898qvb.40.2024.03.08.07.24.01 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 08 Mar 2024 07:24:01 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-97224-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) client-ip=147.75.199.223; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=dZANEPlx; arc=pass (i=1 spf=pass spfdomain=gmail.com dkim=pass dkdomain=gmail.com dmarc=pass fromdomain=gmail.com); spf=pass (google.com: domain of linux-kernel+bounces-97224-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-97224-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id 7964A1C2184A for ; Fri, 8 Mar 2024 15:24:01 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id B72AA1F94C; Fri, 8 Mar 2024 15:23:46 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="dZANEPlx" Received: from mail-pj1-f43.google.com (mail-pj1-f43.google.com [209.85.216.43]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 6DDD115C0; Fri, 8 Mar 2024 15:23:44 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.216.43 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709911425; cv=none; b=ebjnSqVdpg6RtvmrOzVfFXIokDPH58wwF8WTkluEFPYRR63IMxyxG5GuB27eFLf3Xc29n/CsOQIU8udx8lHYLzBvnXo0uRULkSI1zeJ0OqQV+fcRjcftHRqn9gCtYGMIX5NTY3DrLNWCxklVtYg++p0y+/zSwzQ3S8aNuPkXTzM= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709911425; c=relaxed/simple; bh=smFQqtDCLvrCK6zU35YKk9vivzb3zYgAYB2LYuAuGDE=; h=MIME-Version:References:In-Reply-To:From:Date:Message-ID:Subject: To:Cc:Content-Type; b=pvrQ0Xu4nWlu+P/ME4DqMfkXhTzh3V70ChZXG636Sw8AF6pf2GRmSMDK8XfF97jP31UAulgzIOwPTiWSCRjy0uEXhl1TvsKgmnTiBYHzSqGJ8XZ2DTZYoyY3uJWnAvx1l6pD1YETMDLmSMqSjMoN5956/aRKQG84aq5ShhuSvt4= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=dZANEPlx; arc=none smtp.client-ip=209.85.216.43 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Received: by mail-pj1-f43.google.com with SMTP id 98e67ed59e1d1-29a61872f4eso1490952a91.2; Fri, 08 Mar 2024 07:23:44 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1709911424; x=1710516224; darn=vger.kernel.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=bcBcmCbNUNK8QMRYlD0suSpFuYeDhzgpUC/IVV9/I8w=; b=dZANEPlxwM5oPCBvysfsLEwt5BNASQmYvo5PvBmmGsOI0UnLaIxwoweL9P6HcyPFvD dIvcarMHLLGKTwrwX9ysbLHqaypr+WoqFDdtx8/vF7IhIW3ZFwfijegrKLpMajWzpXfI ISsSSJvPVm17jdRrvEDTbuGeoaX6SxUAZwi/gvwMt8GTe6ST5CyfW4RAHlAa2f0OjVHY 7I6PJXSq1M5pG1UEwxsjgfKMy3pvmWVsp137FG7NzkV4McQIZMdsdsf3HAvWfcSQPwCA FA+EGg6mFMCV3iA94fY9KXnjdu3xq1MmKIO69AuVyPBMJ1rgwfKVrbHBU8IxUCz0jjdF 3oew== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1709911424; x=1710516224; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=bcBcmCbNUNK8QMRYlD0suSpFuYeDhzgpUC/IVV9/I8w=; b=m1zEzv8mmpofpKmxvVpDtIoN0TkV+k0thCTcH2XBbOy1eVwNaZ8hFTJOUzthKXRzuM TU8gdo5LEXWUVfNuztImE2Fw80pm3Hpq+e1rDl9QPJuvMHKYbHmtr3gLMqmy4X110OG+ gJzRng4EDN9wnPuwNea7atLZ/g8G7JcuxP4OusoOX8g+cQ9RUKh85ccVkp1sa60SzxnX DFfe7EV/tKtgIH0e2SccRbs+nHcpJlHUsMPDaJ71Kw4A+f6S85fODME+KAOp3Un0QGR9 uS/qdZZE2MUPR1GftTsSJ0KbzkLJQgiK6KA6MSKOX1RvK0jjUx5guERbH8tkXc9bUZuN yaxA== X-Forwarded-Encrypted: i=1; AJvYcCVaMoiBGTKQ5WlIYqVj3vXjZrqJGkFyTMfGkwnQJ5Eaz/vegg3IC3o6Hba9rMRCITih2W4OJwziEbKC3lkSwPXK+hAcU60AakJ4n408zdBi6CiHRLWQ5GQOjE+aToz3SLTeJGehLITWmtIhFXuTDYqJYlXRUawEpdQt5koV4YvNbvP6rhZqS/Qkh1xWGLnUWfnyYF8KP3gkh1nu4BaiimerkPgkf4DHHxB/riBjNv88IqO8Mfo9kpzXaxdfqNLfyV0Y4xNbSyDgL6b63mSR/DB6SDhFb/MO45SjJ2T27PHpyNRSciD8ilNYSerY4jZEN32Fw3+//nUbKGC7 X-Gm-Message-State: AOJu0Yyc+eaKz47yYcEHXvrA3cMxcGFkwPQNL7dqbfVq8289YvnnaMZN DZGv6i5zVPf/VOPV1FyGL+aH9qB7M+sZEyoG1KTXGuYeno3pOLNNR8Ki71MEtcAYPngOdNLsPKe z9Gp+1MrqUcB9JquCKE2758yNhXc= X-Received: by 2002:a17:90b:613:b0:29b:90d7:36dc with SMTP id gb19-20020a17090b061300b0029b90d736dcmr281082pjb.19.1709911423609; Fri, 08 Mar 2024 07:23:43 -0800 (PST) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 References: <20240306182440.2003814-1-surenb@google.com> <20240306182440.2003814-25-surenb@google.com> In-Reply-To: <20240306182440.2003814-25-surenb@google.com> From: Miguel Ojeda Date: Fri, 8 Mar 2024 16:23:30 +0100 Message-ID: Subject: Re: [PATCH v5 24/37] rust: Add a rust helper for krealloc() To: Suren Baghdasaryan Cc: akpm@linux-foundation.org, kent.overstreet@linux.dev, mhocko@suse.com, vbabka@suse.cz, hannes@cmpxchg.org, roman.gushchin@linux.dev, mgorman@suse.de, dave@stgolabs.net, willy@infradead.org, liam.howlett@oracle.com, penguin-kernel@i-love.sakura.ne.jp, corbet@lwn.net, void@manifault.com, peterz@infradead.org, juri.lelli@redhat.com, catalin.marinas@arm.com, will@kernel.org, arnd@arndb.de, tglx@linutronix.de, mingo@redhat.com, dave.hansen@linux.intel.com, x86@kernel.org, peterx@redhat.com, david@redhat.com, axboe@kernel.dk, mcgrof@kernel.org, masahiroy@kernel.org, nathan@kernel.org, dennis@kernel.org, jhubbard@nvidia.com, tj@kernel.org, muchun.song@linux.dev, rppt@kernel.org, paulmck@kernel.org, pasha.tatashin@soleen.com, yosryahmed@google.com, yuzhao@google.com, dhowells@redhat.com, hughd@google.com, andreyknvl@gmail.com, keescook@chromium.org, ndesaulniers@google.com, vvvvvv@google.com, gregkh@linuxfoundation.org, ebiggers@google.com, ytcoode@gmail.com, vincent.guittot@linaro.org, dietmar.eggemann@arm.com, rostedt@goodmis.org, bsegall@google.com, bristot@redhat.com, vschneid@redhat.com, cl@linux.com, penberg@kernel.org, iamjoonsoo.kim@lge.com, 42.hyeyoo@gmail.com, glider@google.com, elver@google.com, dvyukov@google.com, shakeelb@google.com, songmuchun@bytedance.com, jbaron@akamai.com, aliceryhl@google.com, rientjes@google.com, minchan@google.com, kaleshsingh@google.com, kernel-team@android.com, linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org, iommu@lists.linux.dev, linux-arch@vger.kernel.org, linux-fsdevel@vger.kernel.org, linux-mm@kvack.org, linux-modules@vger.kernel.org, kasan-dev@googlegroups.com, cgroups@vger.kernel.org, Miguel Ojeda , Alex Gaynor , Wedson Almeida Filho , Boqun Feng , Gary Guo , =?UTF-8?Q?Bj=C3=B6rn_Roy_Baron?= , Benno Lossin , Andreas Hindborg , rust-for-linux@vger.kernel.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Wed, Mar 6, 2024 at 7:26=E2=80=AFPM Suren Baghdasaryan wrote: > > +void * __must_check rust_helper_krealloc(const void *objp, size_t new_si= ze, > + gfp_t flags) __realloc_size(2) The `__realloc_size(2)` should be placed earlier, i.e. this triggers: rust/helpers.c:162:20: error: GCC does not allow '__alloc_size__' attribute in this position on a function definition [-Wgcc-compat] With that fixed: Acked-by: Miguel Ojeda Cheers, Miguel