From owner-dev-commits-src-all@freebsd.org Thu Apr 29 20:20:11 2021 Return-Path: Delivered-To: dev-commits-src-all@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id B627363573E; Thu, 29 Apr 2021 20:20:11 +0000 (UTC) (envelope-from cy.schubert@cschubert.com) Received: from smtp-out-so.shaw.ca (smtp-out-so.shaw.ca [64.59.136.139]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "Client", Issuer "CA" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4FWRgv1z66z3FSG; Thu, 29 Apr 2021 20:20:10 +0000 (UTC) (envelope-from cy.schubert@cschubert.com) Received: from spqr.komquats.com ([70.66.148.124]) by shaw.ca with ESMTPA id cD8plxAG3WLldcD8qlyuMI; Thu, 29 Apr 2021 14:20:09 -0600 X-Authority-Analysis: v=2.4 cv=H8e4f8Ui c=1 sm=1 tr=0 ts=608b14f9 a=Cwc3rblV8FOMdVN/wOAqyQ==:117 a=Cwc3rblV8FOMdVN/wOAqyQ==:17 a=kj9zAlcOel0A:10 a=3YhXtTcJ-WEA:10 a=YxBL1-UpAAAA:8 a=6I5d2MoRAAAA:8 a=EkcXrb_YAAAA:8 a=IuY_kKPIDeSZ4UYW2gEA:9 a=CjuIK1q_8ugA:10 a=Ia-lj3WSrqcvXOmTRaiG:22 a=IjZwj45LgO3ly-622nXo:22 a=LK5xJRSDVpKd5WXXoEvA:22 Received: from slippy.cwsent.com (slippy [10.1.1.91]) by spqr.komquats.com (Postfix) with ESMTPS id 583F979E; Thu, 29 Apr 2021 13:20:06 -0700 (PDT) Received: from slippy (localhost [127.0.0.1]) by slippy.cwsent.com (8.16.1/8.16.1) with ESMTP id 13TKK6a4010861; Thu, 29 Apr 2021 13:20:06 -0700 (PDT) (envelope-from Cy.Schubert@cschubert.com) Message-Id: <202104292020.13TKK6a4010861@slippy.cwsent.com> X-Mailer: exmh version 2.9.0 11/07/2018 with nmh-1.7.1 Reply-to: Cy Schubert From: Cy Schubert X-os: FreeBSD X-Sender: cy@cwsent.com X-URL: http://www.cschubert.com/ To: Michael Gmelin cc: Cy Schubert , src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Subject: Re: git: a0358e3d5184 - main - Synch index of contrib/bc with what is in workdir after cloning. In-reply-to: <20210429200740.5e8bfe5a@bsd64.grem.de> References: <202104291234.13TCYk5K092776@gitrepo.freebsd.org> <202104291353.13TDrIg3026309@slippy.cwsent.com> <20210429162959.16662d66@bsd64.grem.de> <202104291455.13TEtxEg040285@slippy.cwsent.com> <20210429172122.1751663f@bsd64.grem.de> <202104291730.13THUOv6006096@slippy.cwsent.com> <20210429200740.5e8bfe5a@bsd64.grem.de> Comments: In-reply-to Michael Gmelin message dated "Thu, 29 Apr 2021 20:07:40 +0200." Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Thu, 29 Apr 2021 13:20:06 -0700 X-CMAE-Envelope: MS4xfKVoqjPGoYe/EeHRwt1Xu+dKbLfv3TrD9Y9lgAppLjuB8sCYtXNBuiXNyBFxEwC5gOMnHdaMEcC8qXh/srwS8SYw3SUlOOheKmIIcq4xyvrevffTnBRP rhaci2Yf3EyTW73a5jKweAicLr3ewDP9ItqS0/NV1zoWgBQQAv65j+QfaoswtpzWBv7X+ftzVP5L+u4g2TIq4qsXblqnd9mqw2e75I74S3a2wfHDjywIyuCQ 3vxng4Z1BHUqEeIXXHTI/kA43fZ0JUskhKEgViWuFQNMFIjFQPcrXQNoY8JgPjezhEQSjDl5L6Uy+DrHLhnuYykHZn/2aC1z+/ytN8G2/JY= X-Rspamd-Queue-Id: 4FWRgv1z66z3FSG X-Spamd-Bar: ---- Authentication-Results: mx1.freebsd.org; none X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[] X-BeenThere: dev-commits-src-all@freebsd.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Commit messages for all branches of the src repository List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 29 Apr 2021 20:20:11 -0000 In message <20210429200740.5e8bfe5a@bsd64.grem.de>, Michael Gmelin writes: > > > On Thu, 29 Apr 2021 10:30:24 -0700 > Cy Schubert wrote: > > > Going back in time through each daily snapshot, my April 26 0230U > > snapshot first exhibited the problem. > > Yes, like I wrote, the problem was introduced in 8ea9013512 (which was > on April 26th). > > If you take your snapshot from - let's say - April 27th, you can also > easily demonstrate the problem by doing: > > cp -a /usr/src /usr/srccopy > cd /usr/src/srccopy > git status No luck with this. > > Or by doing: > > cd /usr/src > rm .git/index > git reset > git status No luck with this either: slippy$ pwd /x/test/29 slippy$ rm .git/index slippy$ git reset Unstaged changes after reset: M contrib/bc/bc.vcxproj M contrib/bc/bc.vcxproj.filters M contrib/bc/bcl.vcxproj M contrib/bc/bcl.vcxproj.filters M etc/mtree/BSD.var.dist M sys/dev/bge/if_bge.c M sys/dev/bge/if_bgereg.h M sys/geom/geom.h M sys/geom/geom_int.h M sys/geom/geom_kern.c M sys/geom/geom_subr.c It took 404.90 seconds to enumerate unstaged changes after reset. You can use '--quiet' to avoid this. Set the config setting reset.quiet to true to make this the default. slippy$ git st Refresh index: 100% (86556/86556), done. On branch komquats Changes not staged for commit: (use "git add ..." to update what will be committed) (use "git restore ..." to discard changes in working directory) modified: contrib/bc/bc.vcxproj modified: contrib/bc/bc.vcxproj.filters modified: contrib/bc/bcl.vcxproj modified: contrib/bc/bcl.vcxproj.filters modified: etc/mtree/BSD.var.dist modified: sys/dev/bge/if_bge.c modified: sys/dev/bge/if_bgereg.h modified: sys/geom/geom.h modified: sys/geom/geom_int.h modified: sys/geom/geom_kern.c modified: sys/geom/geom_subr.c Untracked files: (use "git add ..." to include in what will be committed) sys/i386/conf/IPFILTER usr.sbin/ufdformat/ no changes added to commit (use "git add" and/or "git commit -a") slippy$ git stash push -m foobar Saved working directory and index state On komquats: foobar slippy$ git st On branch komquats Changes not staged for commit: (use "git add ..." to update what will be committed) (use "git restore ..." to discard changes in working directory) modified: contrib/bc/bc.vcxproj modified: contrib/bc/bc.vcxproj.filters modified: contrib/bc/bcl.vcxproj modified: contrib/bc/bcl.vcxproj.filters Untracked files: (use "git add ..." to include in what will be committed) sys/i386/conf/IPFILTER usr.sbin/ufdformat/ no changes added to commit (use "git add" and/or "git commit -a") slippy$ > > or by doing: > > cd /usr/src > touch contrib/bc/*vcx* > git status Same slippy$ touch contrib/bc/*vcx* You have new mail. slippy$ git st On branch komquats Changes not staged for commit: (use "git add ..." to update what will be committed) (use "git restore ..." to discard changes in working directory) modified: contrib/bc/bc.vcxproj modified: contrib/bc/bc.vcxproj.filters modified: contrib/bc/bcl.vcxproj modified: contrib/bc/bcl.vcxproj.filters Untracked files: (use "git add ..." to include in what will be committed) sys/i386/conf/IPFILTER usr.sbin/ufdformat/ no changes added to commit (use "git add" and/or "git commit -a") slippy$ Next I tried committing the following to the branch: slippy$ git br * komquats main slippy$ git ci contrib/bc/bc.vcxproj contrib/bc/bc.vcxproj.filters contrib/bc/bcl.vcxproj contrib/bc/bcl.vcxproj.filters hint: Waiting for your editor to close the file... Foobar. # Please enter the commit message for your changes. Lines starting # with '#' will be ignored, and an empty message aborts the commit. # # On branch komquats # Changes to be committed: # modified: contrib/bc/bc.vcxproj # modified: contrib/bc/bc.vcxproj.filters # modified: contrib/bc/bcl.vcxproj # modified: contrib/bc/bcl.vcxproj.filters # # Untracked files: # sys/i386/conf/IPFILTER # usr.sbin/ufdformat/ # ~ ~ ~ ~ ~ ~ ~ ~ /x/test/29/.git/COMMIT_EDITMSG: 15 lines, 425 characters [komquats 1155c1951d3c] Foobar. 4 files changed, 713 insertions(+), 713 deletions(-) slippy$ git co main Switched to branch 'main' Your branch is up to date with 'freebsd/main'. slippy$ git co komquats error: Your local changes to the following files would be overwritten by checkout: contrib/bc/bc.vcxproj contrib/bc/bc.vcxproj.filters contrib/bc/bcl.vcxproj contrib/bc/bcl.vcxproj.filters Please commit your changes or stash them before you switch branches. Aborting slippy$ git st On branch main Your branch is up to date with 'freebsd/main'. Changes not staged for commit: (use "git add ..." to update what will be committed) (use "git restore ..." to discard changes in working directory) modified: contrib/bc/bc.vcxproj modified: contrib/bc/bc.vcxproj.filters modified: contrib/bc/bcl.vcxproj modified: contrib/bc/bcl.vcxproj.filters Untracked files: (use "git add ..." to include in what will be committed) sys/i386/conf/IPFILTER usr.sbin/ufdformat/ no changes added to commit (use "git add" and/or "git commit -a") slippy$ The only solution is to rm the files, checkout main, blow away the branch and recreate it. And that, only before checking out main or main itself hosed. I already did this, the following this morning. This is more an academic exercise on my part: Rollback snapshot. slippy$ git br * komquats main slippy$ git stash push -m my-work Saved working directory and index state On komquats: my-work slippy$ git st On branch komquats Untracked files: (use "git add ..." to include in what will be committed) sys/i386/conf/IPFILTER usr.sbin/ufdformat/ nothing added to commit but untracked files present (use "git add" to track) slippy$ git co main Switched to branch 'main' Your branch is up to date with 'freebsd/main'. slippy$ git st On branch main Your branch is up to date with 'freebsd/main'. Untracked files: (use "git add ..." to include in what will be committed) sys/i386/conf/IPFILTER usr.sbin/ufdformat/ nothing added to commit but untracked files present (use "git add" to track) slippy$ git pull -r --all Fetching freebsd remote: Enumerating objects: 35, done. remote: Counting objects: 100% (35/35), done. remote: Total 144 (delta 34), reused 34 (delta 34), pack-reused 109 Receiving objects: 100% (144/144), 99.01 KiB | 355.00 KiB/s, done. Resolving deltas: 100% (86/86), completed with 19 local objects. >From https://git.freebsd.org/src a4b5f7ba3e9b..420d30f5bdbf main -> freebsd/main 1a34afa9541e..aa4eb2089751 stable/13 -> freebsd/stable/13 Updating a4b5f7ba3e9b..420d30f5bdbf Fast-forward contrib/bc/bc.vcxproj | 554 ++++++++++++++++++++------------------ --- contrib/bc/bc.vcxproj.filters | 362 +++++++++++++-------------- contrib/bc/bcl.vcxproj | 320 ++++++++++++------------ contrib/bc/bcl.vcxproj.filters | 190 +++++++------- release/arm/armv7.conf | 8 + share/man/man9/kasan.9 | 22 +- share/mk/src.libnames.mk | 3 - sys/amd64/amd64/pmap.c | 2 +- sys/dev/ipmi/ipmi_isa.c | 4 + sys/dev/ipmi/ipmi_pci.c | 4 + sys/dev/ipmi/ipmi_smbios.c | 19 +- sys/dev/ipmi/ipmi_smbus.c | 4 + sys/kern/subr_asan.c | 10 +- sys/netpfil/pf/pf_nv.c | 8 +- sys/sys/asan.h | 2 +- 15 files changed, 776 insertions(+), 736 deletions(-) create mode 100644 release/arm/armv7.conf slippy$ git co komquats Switched to branch 'komquats' slippy$ git rebase main error: cannot rebase: You have unstaged changes. error: Please commit or stash them. slippy$ git st On branch komquats Changes not staged for commit: (use "git add ..." to update what will be committed) (use "git restore ..." to discard changes in working directory) modified: contrib/bc/bc.vcxproj modified: contrib/bc/bc.vcxproj.filters modified: contrib/bc/bcl.vcxproj modified: contrib/bc/bcl.vcxproj.filters Untracked files: (use "git add ..." to include in what will be committed) sys/i386/conf/IPFILTER usr.sbin/ufdformat/ no changes added to commit (use "git add" and/or "git commit -a") slippy$ rm contrib/bc/bc.vcxproj contrib/bc/bc.vcxproj.filters contrib/bc/bcl.vcxproj contrib/bc/bcl.vcxproj.filters slippy$ git co main Switched to branch 'main' Your branch is up to date with 'freebsd/main'. slippy$ git st On branch main Your branch is up to date with 'freebsd/main'. Untracked files: (use "git add ..." to include in what will be committed) sys/i386/conf/IPFILTER usr.sbin/ufdformat/ nothing added to commit but untracked files present (use "git add" to track) slippy$ git br -d komquats Deleted branch komquats (was 41ce0e34ea42). slippy$ git co -b komquats Switched to a new branch 'komquats' slippy$ git stash pop On branch komquats Changes not staged for commit: (use "git add ..." to update what will be committed) (use "git restore ..." to discard changes in working directory) modified: etc/mtree/BSD.var.dist modified: sys/dev/bge/if_bge.c modified: sys/dev/bge/if_bgereg.h modified: sys/geom/geom.h modified: sys/geom/geom_int.h modified: sys/geom/geom_kern.c modified: sys/geom/geom_subr.c Untracked files: (use "git add ..." to include in what will be committed) sys/i386/conf/IPFILTER usr.sbin/ufdformat/ no changes added to commit (use "git add" and/or "git commit -a") Dropped refs/stash@{0} (33071593e430eeaa3782d582534c057c968776f6) slippy$ I didn't have any committed work in this branch so recreating the branch from scratch was painless. > > > > > My remediation efforts are below: > > > >> ... > > slippy$ > > > > > > There is no way to move forward except to rm (not git rm but UNIX rm) > > the files. Checkout another branch and blow away the affected branch. > > With the files physically deleted with rm(1) I could switch branches > > and blow away the affected branch. Without this extreme I can't even > > switch branches. > > AFAIK there are two options forward: > > 1. Simply add the files that are shown as changed on your local branch > (that's all my commit did, "git commit -a"). > 2. Temporarily do: > echo "contrib/bc/bc*.vcx* -text" >>.git/info/attributes Neither of those worked for me. Again this is purely academic now but looking to understand this should it happen again, with committed work. > > > > > Lucky for me this branch was a placeholder maintaining a record of > > what was installed on my laptop vs main, so it's easy to blow away > > and recreate. But for people with committed changes to a branch this > > would be a huge problem. > > The two things above should work. > > > > > My other branches which I rebase much less frequently were unaffected. > > > > > > AFAIK this only affects branches which happen to contain changes > since 8ea9013512. > > If not, I'm afraid some breaking repo-surgery would be required, going > back before 8ea9013512 (just doing a revert patch won't accomplish > anything different). I've saved the entire zfs filesystem tree in a zfs-send stream for more experimentation later. Hopefully my notes above are of some value to someone. -- Cheers, Cy Schubert FreeBSD UNIX: Web: https://FreeBSD.org NTP: Web: https://nwtime.org The need of the many outweighs the greed of the few.