Re: git: 6d4a140acfdf - main - pf: Ensure that st->kif is obtained in a way which respects the r->rpool->mtx mutex

2024-02-06 Thread Warner Losh
On Tue, Feb 6, 2024 at 9:27 AM Kristof Provost  wrote:

> > I need to land my -c flag that automates git arc patch more...
>
> If that does what I think it does (i.e. commit the patch locally, rather
> than just staging it) you do indeed need to land that. It’ll be very
> helpful.
>

Oh, I already landed it in 787cb30d20ac2031283c6dc2ec829f190997e581. And it
does do what you think: It will use the phabricator APIs to scrape as much
information as it can out of it (author, etc) and commit it so you can not
have to worry about cut and pasting the wrong thing, retyping commit
messages, etc.

Give it a try, and let me know what screws up. Just add '-c' where you'd
use 'git arc patch' today. I have some doodles for pulling the entire chain
down as well, but got side tracked into just getting arc (archanist) to do
that for me and see what the quality of the results are and I never was
happy with the couple of patch trains that I tried.

Warner


Re: git: 6d4a140acfdf - main - pf: Ensure that st->kif is obtained in a way which respects the r->rpool->mtx mutex

2024-02-06 Thread Kristof Provost
On 5 Feb 2024, at 23:27, Warner Losh wrote:
> On Mon, Feb 5, 2024, 11:24 PM Mateusz Guzik  wrote:
>
>> On 2/6/24, Kristof Provost  wrote:
>>> On 5 Feb 2024, at 19:02, Gleb Smirnoff wrote:
 On Mon, Feb 05, 2024 at 09:19:20PM +, Kristof Provost wrote:
 K> The branch main has been updated by kp:
 K>
 K> URL:

>> https://cgit.FreeBSD.org/src/commit/?id=6d4a140acfdf637bb559d371c583e4db478e1549
 K>
 K> commit 6d4a140acfdf637bb559d371c583e4db478e1549
 K> Author: Igor Ostapenko 
 K> AuthorDate: 2024-02-05 16:22:31 +
 K> Commit: Kristof Provost 
 K> CommitDate: 2024-02-05 21:18:11 +

 The author should be Kajetan :(
>>>
>>> Indeed it should. My apologies to Kajetan. And Igor as well, although he
>>> probably got the better end of the deal.
>>>
>>
>> You can revert and commit the correct version.
>>
>
> The counts would still count the bad version though...

I’ve done the revert/re-apply dance anyway, so git annotate will show the 
correct author.

> I need to land my -c flag that automates git arc patch more...

If that does what I think it does (i.e. commit the patch locally, rather than 
just staging it) you do indeed need to land that. It’ll be very helpful.

Best regards,
Kristof



Re: git: 6d4a140acfdf - main - pf: Ensure that st->kif is obtained in a way which respects the r->rpool->mtx mutex

2024-02-05 Thread Warner Losh
On Mon, Feb 5, 2024, 11:24 PM Mateusz Guzik  wrote:

> On 2/6/24, Kristof Provost  wrote:
> > On 5 Feb 2024, at 19:02, Gleb Smirnoff wrote:
> >> On Mon, Feb 05, 2024 at 09:19:20PM +, Kristof Provost wrote:
> >> K> The branch main has been updated by kp:
> >> K>
> >> K> URL:
> >>
> https://cgit.FreeBSD.org/src/commit/?id=6d4a140acfdf637bb559d371c583e4db478e1549
> >> K>
> >> K> commit 6d4a140acfdf637bb559d371c583e4db478e1549
> >> K> Author: Igor Ostapenko 
> >> K> AuthorDate: 2024-02-05 16:22:31 +
> >> K> Commit: Kristof Provost 
> >> K> CommitDate: 2024-02-05 21:18:11 +
> >>
> >> The author should be Kajetan :(
> >
> > Indeed it should. My apologies to Kajetan. And Igor as well, although he
> > probably got the better end of the deal.
> >
>
> You can revert and commit the correct version.
>

The counts would still count the bad version though...

I need to land my -c flag that automates git arc patch more...

Warner

-- 
> Mateusz Guzik 
>


Re: git: 6d4a140acfdf - main - pf: Ensure that st->kif is obtained in a way which respects the r->rpool->mtx mutex

2024-02-05 Thread Mateusz Guzik
On 2/6/24, Kristof Provost  wrote:
> On 5 Feb 2024, at 19:02, Gleb Smirnoff wrote:
>> On Mon, Feb 05, 2024 at 09:19:20PM +, Kristof Provost wrote:
>> K> The branch main has been updated by kp:
>> K>
>> K> URL:
>> https://cgit.FreeBSD.org/src/commit/?id=6d4a140acfdf637bb559d371c583e4db478e1549
>> K>
>> K> commit 6d4a140acfdf637bb559d371c583e4db478e1549
>> K> Author: Igor Ostapenko 
>> K> AuthorDate: 2024-02-05 16:22:31 +
>> K> Commit: Kristof Provost 
>> K> CommitDate: 2024-02-05 21:18:11 +
>>
>> The author should be Kajetan :(
>
> Indeed it should. My apologies to Kajetan. And Igor as well, although he
> probably got the better end of the deal.
>

You can revert and commit the correct version.

-- 
Mateusz Guzik 



Re: git: 6d4a140acfdf - main - pf: Ensure that st->kif is obtained in a way which respects the r->rpool->mtx mutex

2024-02-05 Thread Gleb Smirnoff
On Mon, Feb 05, 2024 at 07:08:39PM -0700, Kristof Provost wrote:
K> > K> commit 6d4a140acfdf637bb559d371c583e4db478e1549
K> > K> Author: Igor Ostapenko 
K> > K> AuthorDate: 2024-02-05 16:22:31 +
K> > K> Commit: Kristof Provost 
K> > K> CommitDate: 2024-02-05 21:18:11 +
K> > 
K> > The author should be Kajetan :(
K> 
K> Indeed it should. My apologies to Kajetan. And Igor as well, although he
K> probably got the better end of the deal.
K> 
K> > I guess you were working on several reviews at a time and had name in
K> > paste buffer. :(
K> 
K> Not exactly. I had grabbed the patch with `git arc patch D43741`, tested it
K> and committed with `git commit —author=…`.
K> I’ve committed enough patches from both Kajetan and Igor that they’re both
K> in my shell history, and I had a brainfart and grabbed the wrong git commit
K> line.
K> 
K> Again, my apologies to both for the confusion.

I believe both will submit hundred more patches soon and this +1/-1 won't
make a big difference :)

-- 
Gleb Smirnoff



Re: git: 6d4a140acfdf - main - pf: Ensure that st->kif is obtained in a way which respects the r->rpool->mtx mutex

2024-02-05 Thread Kristof Provost

On 5 Feb 2024, at 19:02, Gleb Smirnoff wrote:

On Mon, Feb 05, 2024 at 09:19:20PM +, Kristof Provost wrote:
K> The branch main has been updated by kp:
K>
K> URL: 
https://cgit.FreeBSD.org/src/commit/?id=6d4a140acfdf637bb559d371c583e4db478e1549

K>
K> commit 6d4a140acfdf637bb559d371c583e4db478e1549
K> Author: Igor Ostapenko 
K> AuthorDate: 2024-02-05 16:22:31 +
K> Commit: Kristof Provost 
K> CommitDate: 2024-02-05 21:18:11 +

The author should be Kajetan :(


Indeed it should. My apologies to Kajetan. And Igor as well, although he 
probably got the better end of the deal.


I guess you were working on several reviews at a time and had name in 
paste buffer. :(


Not exactly. I had grabbed the patch with `git arc patch D43741`, tested 
it and committed with `git commit —author=…`.
I’ve committed enough patches from both Kajetan and Igor that 
they’re both in my shell history, and I had a brainfart and grabbed 
the wrong git commit line.


Again, my apologies to both for the confusion.

Best regards,
Kristof


Re: git: 6d4a140acfdf - main - pf: Ensure that st->kif is obtained in a way which respects the r->rpool->mtx mutex

2024-02-05 Thread Gleb Smirnoff
On Mon, Feb 05, 2024 at 09:19:20PM +, Kristof Provost wrote:
K> The branch main has been updated by kp:
K> 
K> URL: 
https://cgit.FreeBSD.org/src/commit/?id=6d4a140acfdf637bb559d371c583e4db478e1549
K> 
K> commit 6d4a140acfdf637bb559d371c583e4db478e1549
K> Author: Igor Ostapenko 
K> AuthorDate: 2024-02-05 16:22:31 +
K> Commit: Kristof Provost 
K> CommitDate: 2024-02-05 21:18:11 +

The author should be Kajetan :(

I guess you were working on several reviews at a time and had name in paste 
buffer. :(

K> pf: Ensure that st->kif is obtained in a way which respects the 
r->rpool->mtx mutex
K> 
K> The redirection pool stored in r->rpool.cur is used for loadbalancing
K> and cur can change whenever loadbalancing happens, which is for every
K> new connection. Therefore it can't be trusted outside of pf_map_addr()
K> and the r->rpool->mtx mutex. After evaluating the ruleset, loadbalancing
K> decission is made in pf_map_addr() called from within pf_create_state()
K> and stored in the state itself.
K> 
K> This patch modifies BOUND_IFACE() so that it only uses the information
K> already stored in the state which has been obtained in a way which
K> respects the r->rpool->mtx mutex.
K> 
K> Reviewed by:kp
K> Differential Revision:  https://reviews.freebsd.org/D43741

-- 
Gleb Smirnoff