Page MenuHomeFreeBSD

Free up the IPI slot used by IPI_STOP_HARD.
ClosedPublic

Authored by neel on Feb 27 2015, 11:17 PM.
Tags
None
Referenced Files
Unknown Object (File)
Tue, Nov 5, 4:56 PM
Unknown Object (File)
Sat, Oct 19, 6:46 PM
Unknown Object (File)
Sun, Oct 13, 3:18 AM
Unknown Object (File)
Oct 1 2024, 5:23 PM
Unknown Object (File)
Sep 29 2024, 11:22 PM
Unknown Object (File)
Sep 21 2024, 8:21 AM
Unknown Object (File)
Sep 4 2024, 11:29 PM
Unknown Object (File)
Sep 2 2024, 3:04 AM
Subscribers
None

Details

Summary

Change the numeric value of IPI_STOP_HARD so it doesn't occupy a valid IPI
slot. This can be done because IPI_STOP_HARD is actually delivered via NMI.

Test Plan

Enter debugger using 'sysctl debug.kdb.enter' which in turn uses IPI_STOP_HARD
to stop other cpus on amd64 and i386 systems.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
No Lint Coverage
Unit
No Test Coverage

Event Timeline

neel retitled this revision from to Free up the IPI slot used by IPI_STOP_HARD..
neel updated this object.
neel edited the test plan for this revision. (Show Details)
neel added reviewers: jhb, kib.
kib edited edge metadata.

Does IPI_STOP_HARD value must fit into 8 bits ? It is not the same as the spurious vector, which should be innocent as well, but slightly confusing.

This revision is now accepted and ready to land.Feb 28 2015, 2:55 AM
In D1983#3, @kostikbel wrote:

Does IPI_STOP_HARD value must fit into 8 bits ? It is not the same as the spurious vector, which should be innocent as well, but slightly confusing.

There were two restrictions when choosing the value for the IPI_STOP_HARD value:

  • 'native_lapic_ipi_vectored()' wants the vector to be less than 256
  • 'xen_ipis[]' requires the vector to be greater than or equal to 243 (APIC_IPI_INTS)
In D1983#6, @neel wrote:
In D1983#3, @kostikbel wrote:

Does IPI_STOP_HARD value must fit into 8 bits ? It is not the same as the spurious vector, which should be innocent as well, but slightly confusing.

There were two restrictions when choosing the value for the IPI_STOP_HARD value:

  • 'native_lapic_ipi_vectored()' wants the vector to be less than 256

So if we change the assertion in native_lapic_ipi_vectored(), the IPI_STOP_HARD value could be moved outside the [0,255] range ? I mean, explicitly allow a value in the valid range OR IPI_STOP_HARD, in the assertion.

I do not insist, as I already indicated, I am fine with the patch as is.

  • 'xen_ipis[]' requires the vector to be greater than or equal to 243 (APIC_IPI_INTS)
In D1983#7, @kostikbel wrote:
In D1983#6, @neel wrote:
In D1983#3, @kostikbel wrote:

Does IPI_STOP_HARD value must fit into 8 bits ? It is not the same as the spurious vector, which should be innocent as well, but slightly confusing.

There were two restrictions when choosing the value for the IPI_STOP_HARD value:

  • 'native_lapic_ipi_vectored()' wants the vector to be less than 256

So if we change the assertion in native_lapic_ipi_vectored(), the IPI_STOP_HARD value could be moved outside the [0,255] range ? I mean, explicitly allow a value in the valid range OR IPI_STOP_HARD, in the assertion.

Yup, that would have worked as well.

I do not insist, as I already indicated, I am fine with the patch as is.

  • 'xen_ipis[]' requires the vector to be greater than or equal to 243 (APIC_IPI_INTS)
neel updated this revision to Diff 4044.

Closed by commit rS279468 (authored by @neel).