From nobody Tue Apr 19 11:34:49 2022 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id E8E0D11DA729; Tue, 19 Apr 2022 11:34:51 +0000 (UTC) (envelope-from mjguzik@gmail.com) Received: from mail-lj1-x231.google.com (mail-lj1-x231.google.com [IPv6:2a00:1450:4864:20::231]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1D4" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4KjMCv2rMbz3hSc; Tue, 19 Apr 2022 11:34:51 +0000 (UTC) (envelope-from mjguzik@gmail.com) Received: by mail-lj1-x231.google.com with SMTP id bf11so8422950ljb.7; Tue, 19 Apr 2022 04:34:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=OrQepMMZEwFTpIAjQKTw7xp+qrlaw19Mq1cmspLk9q4=; b=SRbsfUIPk7g4J6vw6EzhaA5LmB8z0z08Bx+ZdF8mDd/A2cDvcpuEHm8GdbvG/YcWw8 ZAJr92fFce58J4uJAUcHFpWr0QRUOaSW8FXUEYiTsFHDKpRkLSjZK1KB8JOFhn7GnE8O iP/zpI5ZgTwRGUumfjugtFINwvreoMO+2taL9sBILMK2qvF+Ru6qi5g7OGh/tq883UWM s96v7rq+fyw7+jrR8H9SJVOvC2XDPfJiE1sjMfMXgVmuY8K/Tid+K0IcaZ+pnDH51jcM jBCk/glHKdIuzfBJ8+4/MK2yXdic2mz9nqHRUVAuMORk2Dhh3KyoJPeKaP+5WEMG30cp z4HQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=OrQepMMZEwFTpIAjQKTw7xp+qrlaw19Mq1cmspLk9q4=; b=lyD6IG9QphAkHGoBUlzOMb2JbvzDjWSmIQQAtDCUiQylFFSxuBtStk7dfEMTaLjEUM NNDhrLntudPYX85H9MfJAd5D4XzrhvDQrCvtu1dJsS3w+hm5KhFeMxzRJTS9Hl+b1/T9 dFGrlIeMN1937vSGR2dO2M3qAKN9FHB31rgwYU3pcu+16bVLFm06dbtDkFGctlIMxLCq wfEtVZTcWmvMcvDKgQWqotOOrfpuIMSW3KoxNu+9+ZHiQW7rFuP8qksdJFexmmCXH7PL ZTqpWPILjyoICpbMy0pzN6e1KwNQg5ZBsvjKtCQMUkfHqmKP+A3YNqUw3HRLMMGSnusB 607A== X-Gm-Message-State: AOAM532TlGs6LMXhcek33ARivtognHNgkbIKIBSgZOKxUaziO7V/Sj6/ axTQ5edE3BB13H1jW72lCU3FpGllTccF1EL7qrQ9hkHy X-Google-Smtp-Source: ABdhPJy3kAkDfLzrwyRBVFZaW94AydEFxY4C8Sew2lJIgtnYbplIIqn6TgXvCqTuzXGGSzPP8SE+kXvcNySC95SuRW8= X-Received: by 2002:a05:651c:1214:b0:24d:b7de:5c9 with SMTP id i20-20020a05651c121400b0024db7de05c9mr7138591lja.56.1650368089950; Tue, 19 Apr 2022 04:34:49 -0700 (PDT) List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-all@freebsd.org X-BeenThere: dev-commits-src-all@freebsd.org MIME-Version: 1.0 Received: by 2002:a05:6520:6145:b0:1bb:7433:4cdd with HTTP; Tue, 19 Apr 2022 04:34:49 -0700 (PDT) In-Reply-To: <960b9be3-c3b5-bd48-8038-97511f2f7909@FreeBSD.org> References: <202204182311.23INBqfC025671@gitrepo.freebsd.org> <960b9be3-c3b5-bd48-8038-97511f2f7909@FreeBSD.org> From: Mateusz Guzik Date: Tue, 19 Apr 2022 13:34:49 +0200 Message-ID: Subject: Re: git: 8b83d7e0ee54 - main - Make -Wunused-but-set-variable a fatal error for clang 13+ for kernel builds. To: Stefan Esser Cc: John Baldwin , src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org Content-Type: text/plain; charset="UTF-8" X-Rspamd-Queue-Id: 4KjMCv2rMbz3hSc X-Spamd-Bar: --- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=gmail.com header.s=20210112 header.b=SRbsfUIP; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (mx1.freebsd.org: domain of mjguzik@gmail.com designates 2a00:1450:4864:20::231 as permitted sender) smtp.mailfrom=mjguzik@gmail.com X-Spamd-Result: default: False [-3.35 / 15.00]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-1.00)[-0.999]; R_DKIM_ALLOW(-0.20)[gmail.com:s=20210112]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; R_SPF_ALLOW(-0.20)[+ip6:2a00:1450:4000::/36:c]; FREEMAIL_FROM(0.00)[gmail.com]; MIME_GOOD(-0.10)[text/plain]; TO_MATCH_ENVRCPT_ALL(0.00)[]; NEURAL_HAM_LONG(-0.59)[-0.592]; RCPT_COUNT_FIVE(0.00)[5]; MID_RHS_MATCH_FROMTLD(0.00)[]; DKIM_TRACE(0.00)[gmail.com:+]; DMARC_POLICY_ALLOW(-0.50)[gmail.com,none]; RCVD_IN_DNSWL_NONE(0.00)[2a00:1450:4864:20::231:from]; NEURAL_HAM_SHORT(-0.75)[-0.754]; MLMMJ_DEST(0.00)[dev-commits-src-all,dev-commits-src-main]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; FREEMAIL_ENVFROM(0.00)[gmail.com]; ASN(0.00)[asn:15169, ipnet:2a00:1450::/32, country:US]; RCVD_COUNT_TWO(0.00)[2]; RCVD_TLS_ALL(0.00)[]; DWL_DNSWL_NONE(0.00)[gmail.com:dkim] X-ThisMailContainsUnwantedMimeParts: N Looks like this needs a pass on a kernel without AUDIT, MAC, CAPABILITIES, dtrace and probably some other default stuff which also happens to be enabled in all kernel built with tinderbox. On 4/19/22, Stefan Esser wrote: > Am 19.04.22 um 01:11 schrieb John Baldwin: >> The branch main has been updated by jhb: >> >> URL: >> https://cgit.FreeBSD.org/src/commit/?id=8b83d7e0ee54416b0ee58bd85f9c0ae7fb3357a1 >> >> commit 8b83d7e0ee54416b0ee58bd85f9c0ae7fb3357a1 >> Author: John Baldwin >> AuthorDate: 2022-04-18 23:06:27 +0000 >> Commit: John Baldwin >> CommitDate: 2022-04-18 23:06:27 +0000 >> >> Make -Wunused-but-set-variable a fatal error for clang 13+ for kernel >> builds. >> >> Reviewed by: imp, emaste >> Differential Revision: https://reviews.freebsd.org/D34949 > > I'm seeing kernel build issues in several drivers (at commit f2edc9155721). > > The first one could be fixed this way: > > diff --git a/sys/dev/cxgbe/tom/t4_cpl_io.c b/sys/dev/cxgbe/tom/t4_cpl_io.c > index 4c8b1fa27579..470f03313b72 100644 > --- a/sys/dev/cxgbe/tom/t4_cpl_io.c > +++ b/sys/dev/cxgbe/tom/t4_cpl_io.c > @@ -2192,7 +2192,7 @@ static void > t4_aiotx_process_job(struct toepcb *toep, struct socket *so, struct kaiocb > *job) > { > struct sockbuf *sb; > +#ifdef MAC > struct file *fp; > +#endif > struct inpcb *inp; > struct tcpcb *tp; > struct mbuf *m; > @@ -2201,10 +2201,10 @@ t4_aiotx_process_job(struct toepcb *toep, struct > socket > *so, struct kaiocb *job) > > sb = &so->so_snd; > SOCKBUF_UNLOCK(sb); > - fp = job->fd_file; > m = NULL; > > #ifdef MAC > + fp = job->fd_file; > error = mac_socket_check_send(fp->f_cred, so); > if (error != 0) > goto out; > > But then the build failed again at: > > /usr/src/sys/fs/ext2fs/ext2_extents.c:452:8: error: variable 'error_msg' > set > but not used [-Werror,-Wunused-but-set-variable] > Building /usr/obj/usr-14/git/src/amd64.amd64/sys/SE/vdev_mirror.o > > I have stopped trying to fix this and (any remaining) issues and have > locally reverted the commit that made this warning fatal ... > > Regards, STefan > -- Mateusz Guzik