Skip to content

arch/intel64: add CPU affinity support for irq#18602

Open
raiden00pl wants to merge 1 commit intoapache:masterfrom
szafonimateusz-mi:x86_cpu_affinity
Open

arch/intel64: add CPU affinity support for irq#18602
raiden00pl wants to merge 1 commit intoapache:masterfrom
szafonimateusz-mi:x86_cpu_affinity

Conversation

@raiden00pl
Copy link
Member

Summary

arch/intel64: add CPU affinity support for irq

Impact

required for intel64 to compile with this change #18601

Testing

ctucanfd on intel64 works with this change #18601

@github-actions github-actions bot added Arch: x86_64 Issues related to the x86_64 architecture Size: S The size of the change in this PR is small labels Mar 25, 2026
add CPU affinity support for interrupts (up_affinity_irq)

Signed-off-by: p-szafonimateusz <p-szafonimateusz@xiaomi.com>
if (CPU_ISSET(cpu, &cpuset))
{
data = x86_64_cpu_to_loapic(cpu) << 24;
up_ioapic_write(IOAPIC_REG_TABLE + (irq - IRQ0) * 2 + 1, data);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
up_ioapic_write(IOAPIC_REG_TABLE + (irq - IRQ0) * 2 + 1, data);
flags = spin_lock_irqsave(&g_irq_spinlock);
up_ioapic_write(IOAPIC_REG_TABLE + (irq - IRQ0) * 2 + 1, data);
spin_unlock_irqrestore(&g_irq_spinlock, flags);

Maybe we can narrow the lock scope.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Arch: x86_64 Issues related to the x86_64 architecture Size: S The size of the change in this PR is small

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants