Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1420264

Re: [PATCH v2 3/3] x86/quirks: Add early quirk to reset Apple AirPort card

From Lukas Wunner <lukas@wunner.de>
Newsgroups linux.kernel
Subject Re: [PATCH v2 3/3] x86/quirks: Add early quirk to reset Apple AirPort card
Date 2016-06-12 14:40 +0200
Message-ID <rJcQh-ei-13@gated-at.bofh.it> (permalink)
References <rJaY9-7w9-3@gated-at.bofh.it> <rJaY9-7w9-15@gated-at.bofh.it> <rJc3U-88s-15@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Sun, Jun 12, 2016 at 01:49:02PM +0200, Ingo Molnar wrote:
> * Lukas Wunner <lukas@wunner.de> wrote:
> > The solution is to reset the card on boot by writing to a reset bit in
> > its mmio space. This must be done as an early quirk and not as a plain
> > vanilla PCI quirk to successfully combat memory corruption by DMAed
> > packets: Matthew Garrett found out in 2012 that the packets are written
> > to EfiBootServicesData memory (http://mjg59.dreamwidth.org/11235.html).
> > This type of memory is made available to the page allocator by
> > efi_free_boot_services(). [...]
> 
> Btw., would it also make sense to *not* free those pages by default,
> if firmware can occasionally corrupt them? What memory size are we
> talking about?

The memory area where packets are written is relatively small,
Matthew Garret writes: "I'd traced it down to a single 31MB region
of boot service data" (https://mjg59.dreamwidth.org/11235.html)

However memory corruption by DMAed packets is only one of two issues
here. The other is the interrupt storm unleashed by the wireless card.
The IRQ is frequently shared on these models. On my machine it's
shared with the Thunderbolt controller, SDXC controller and a sound
card. I can't even authenticate with cryptsetup on boot before getting
a spurious interrupt splat.

Resetting the card solves the problem at the root and fixes both,
the spurious interrupts and the memory corruption. 

Best regards,

Lukas

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH v2 0/3] Reset Apple AirPort card Lukas Wunner <lukas@wunner.de> - 2016-06-12 12:40 +0200
  [PATCH v2 3/3] x86/quirks: Add early quirk to reset Apple AirPort  card Lukas Wunner <lukas@wunner.de> - 2016-06-12 12:40 +0200
    Re: [PATCH v2 3/3] x86/quirks: Add early quirk to reset Apple  AirPort card Ingo Molnar <mingo@kernel.org> - 2016-06-12 13:50 +0200
      Re: [PATCH v2 3/3] x86/quirks: Add early quirk to reset Apple  AirPort card Lukas Wunner <lukas@wunner.de> - 2016-06-12 14:40 +0200
        Re: [PATCH v2 3/3] x86/quirks: Add early quirk to reset Apple  AirPort card Matt Fleming <matt@codeblueprint.co.uk> - 2016-06-13 16:50 +0200
          Re: [PATCH v2 3/3] x86/quirks: Add early quirk to reset Apple  AirPort card Ingo Molnar <mingo@kernel.org> - 2016-06-14 09:40 +0200

csiph-web