RPI4 clock speeds and serial port (the ~/fbsd-based-on-what-freebsd-main.sh script again)

Mark Millard marklmi at yahoo.com
Sun Mar 28 01:41:14 UTC 2021


On 2021-Mar-25, at 10:19, Mark Millard <marklmi at yahoo.com> wrote:

> On 2021-Mar-25, at 08:09, tech-lists <tech-lists at zyxst.net> wrote:
> 
>> On Thu, Mar 18, 2021 at 12:05:54PM -0700, Mark Millard via freebsd-arm wrote:
>> 
>>> # ~/fbsd-based-on-what-freebsd-main.sh
>> 
>> I've seen you reference this more than once. I guess it's a handy list of git
>> commands. Please tell us what's in it/what it does?
>> 
>> The reason I'm asking is i'm still trying to get my head around git. As
>> someone who is much more a sysadmin than a developer, svn did way more
>> for me than git. The commands I miss most are svn info <path> and svn up -r <version-number>
> 
> I made the possibly-unusual choice to experiment
> with having the FreeBSD patches that I use committed
> in my FreeBSD git environment (in my own branches
> that track FreeBSD updates from freebsd/main). [A
> good portion of the patches are tied to using old
> PowerMacs.]
> 
> This leads to issues reporting what official FreeBSD
> version my context is based on. So I use a script
> for the freebsd/main branch that traces back to a
> common point and reporting back to that common
> point, inclusive of the common point.
> 
> # more ~/fbsd-based-on-what-freebsd-main.sh 
> #! /bin/sh
> base="`git merge-base freebsd/main HEAD`" \
> && echo "merge-base: $base" \
> && base_date="`TZ=UTC git log --format=fuller --date=iso-local --no-color $base^..$base | grep CommitDate:`" \
> && echo "merge-base: $base_date" \
> && git log --oneline --no-color $base^..HEAD \
> && uname -apKU
> 
> It results in output like is shown below:
> 
> # ~/fbsd-based-on-what-freebsd-main.sh 
> merge-base: 7381bbee29df959e88ec59866cf2878263e7f3b2
> merge-base: CommitDate: 2021-03-12 20:29:42 +0000
> def0058cc690 (HEAD -> mm-src) mm-src snapshot for mm's patched build in git context.
> 7381bbee29df (freebsd/main, freebsd/HEAD, pure-src, main) cam: Run all XPT_ASYNC ccbs in a dedicated thread
> FreeBSD RPi4B 14.0-CURRENT FreeBSD 14.0-CURRENT mm-src-n245445-def0058cc690 GENERIC-NODBG  arm64 aarch64 1400005 1400005
> 
> The "merge-base" lines are about the common point.
> The above shows that I've one commit after that
> point: my historical patches are bundled into one
> commit for how I'm working. If I change the patching,
> I might for a time have more than one commit showing
> before the merge base commit is listed.

I'm experimenting with a different order to the
output, uname then newest to oldest, through
merge-base, with merge-base well labeled just
before its line is printed:

# ~/fbsd-based-on-what-freebsd-main.sh
FreeBSD FBSDFHUGE 14.0-CURRENT FreeBSD 14.0-CURRENT mm-src-n245445-def0058cc690 GENERIC-NODBG  amd64 amd64 1400005 1400005
def0058cc690 (HEAD -> mm-src) mm-src snapshot for mm's patched build in git context.
merge-base: 7381bbee29df959e88ec59866cf2878263e7f3b2
merge-base: CommitDate: 2021-03-12 20:29:42 +0000
7381bbee29df (freebsd/main, freebsd/HEAD, pure-src, main) cam: Run all XPT_ASYNC ccbs in a dedicated thread

The updated script looks like:

# more ~/fbsd-based-on-what-freebsd-main.sh
#! /bin/sh
uname -apKU \
&& base="`git merge-base freebsd/main HEAD`" \
&& git log --oneline --no-color $base..HEAD \
&& base_date="`TZ=UTC git log --format=fuller --date=iso-local --no-color $base^..$base | grep CommitDate:`" \
&& echo "merge-base: $base" \
&& echo "merge-base: $base_date" \
&& git log --oneline --no-color $base^..$base


===
Mark Millard
marklmi at yahoo.com
( dsl-only.net went
away in early 2018-Mar)



More information about the freebsd-arm mailing list