> On Aug 25, 2020, at 14:56, Christoph Hellwig <hch@xxxxxxxxxxxxx> wrote: > > On Tue, Aug 25, 2020 at 02:39:55PM +0800, Kai Heng Feng wrote: >> Hi Christoph, >> >>> On Aug 25, 2020, at 2:23 PM, Christoph Hellwig <hch@xxxxxxxxxxxxx> wrote: >>> >>> On Fri, Aug 21, 2020 at 08:32:20PM +0800, Kai-Heng Feng wrote: >>>> New Intel laptops with VMD cannot reach deeper power saving state, >>>> renders very short battery time. >>> >>> So what about just disabling VMD given how bloody pointless it is? >>> Hasn't anyone learned from the AHCI remapping debacle? >>> >>> I'm really pissed at all this pointless crap intel comes up with just >>> to make life hard for absolutely no gain. Is it so hard to just leave >>> a NVMe device as a standard NVMe device instead of f*^&ing everything >>> up in the chipset to make OS support a pain and I/O slower than by >>> doing nothing? >> >> From what I can see from the hardwares at my hand, VMD only enables a PCI domain and PCI bridges behind it. >> >> NVMe works as a regular NVMe under those bridges. No magic remapping happens here. > > It definitively is less bad than the AHCI remapping, that is for sure. > > But it still requires: > > - a new OS driver just to mak the PCIe device show up > - indirections in the irq handling > - indirections in the DMA handling > - hacks for ASPSM > - hacks for X (there were a few more) > > while adding absolutely no value. Basically we have to add a large > chunk of kernel code just to undo silicone/firmware Intel added to their > platform to make things complicated. I mean it is their platform and if > they want a "make things complicated" option that is fine, but it should > not be on by default. Yes, I do want it to be a regular PCIe bridge... but it's not the reality here. Almost all next-gen Intel laptops will have VMD enabled, so users are forced to have it. I would really like to have this patch in upstream instead of carrying it as a downstream distro-only patch. Kai-Heng