From: Balbir Singh <balbirs@nvidia.com>
To: Bert Karwatzki <spasswolf@web.de>
Cc: Ingo Molnar <mingo@kernel.org>, Kees Cook <kees@kernel.org>,
Bjorn Helgaas <bhelgaas@google.com>,
Linus Torvalds <torvalds@linux-foundation.org>,
Peter Zijlstra <peterz@infradead.org>,
Andy Lutomirski <luto@kernel.org>,
linux-kernel@vger.kernel.org
Subject: Re: commit 7ffb791423c7 breaks steam game
Date: Thu, 13 Mar 2025 22:47:52 +1100 [thread overview]
Message-ID: <c7bb0bd1-529d-466d-9cce-abbac4b480ab@nvidia.com> (raw)
In-Reply-To: <a34a1ae0b1d226b1bac7d73daa24da8e5899cb3e.camel@web.de>
On 3/13/25 21:53, Bert Karwatzki wrote:
> Am Donnerstag, dem 13.03.2025 um 21:40 +1100 schrieb Balbir Singh:
>> On 3/13/25 20:22, Bert Karwatzki wrote:
>>> Am Mittwoch, dem 12.03.2025 um 12:24 +1100 schrieb Balbir Singh:
>>>>>>
>>>>>>>
>>>>>>> As a sidenote, I've tested several kernel with nokaslr as command line parameter
>>>>>>> (6.1.128, 6.8.12, 6.12.17 (the debian sid distributional kernel)) and nokaslr is
>>>>>>> not recognized as a command line parameter in any of them
>>>>>>>
>>>>>>
>>>>>> Please see my comment above about booting. How did you check if nokaslr is being
>>>>>> recognized, is it via looking up dmesg?
>>>>>>
>>>>> When I boot with nokaslr I get the following messages in dmesg
>>>>> [ T0] Unknown kernel command line parameters "nokaslr
>>>>> BOOT_IMAGE=/boot/vmlinuz-6.14.0-rc5-next-20250307-master", will be passed to
>>>>> user space.
>>>>>
>>>>> This also happens when I use the debian kernel with standard .config
>>>>
>>>> That is quite strange, I can see nokaslr handling in choose_random_location() in
>>>> arch/x86/boot/compressed/kaslr.c (which depends on CONFIG_RANDOMIZE_BASE)
>>>>
>>>> Thanks,
>>>> Balbir
>>>
>>> The command line parameter nokaslr does actually work, I tested that by booting
>>> the kernel with and without nokaslr and checked /proc/iomem for the physical
>>> address of the kernel. With nokalsr it's always at 0x1200000.
>>>
>>> The warning message in the code
>>> if (cmdline_find_option_bool("nokaslr")) {
>>> warn("KASLR disabled: 'nokaslr' on cmdline.");
>>> return;
>>> }
>>> on the other hand is not shown, because warn is basically __putstr() which
>>> outputs to the serial console and the screen, not the log buffer (Which we do
>>> not have this early in boot anyway, I assume).
>>>
>>> So with this solved I tested stellaris with a kernel without CONFIG_PCI_P2PDMA
>>> and nokaslr and found the same buggy behaviour (i.e. laggy input while stellaris
>>> is running).
>>>
>> Thanks, the system/game is not working correctly accessing memory at 64 TiB
>>
>> I am beginning to wonder what your physical address bits are set to?
>> I can't figure out from lspci, the capabilities of the iommu on your laptop
>>
>> Could you please share your full dmesg/lspci before and after the patch/nokaslr
>> command line.
>>
>> Here is the what I know so far and based on some search I did, I could find
>> your laptop might have a CPU like this one
>> https://openbenchmarking.org/s/AMD+Ryzen+7+3750H
>>
>> It has 43 bits of physical address and sev supported and IIRC sev can change the
>> amount of physical memory accessible, but I am surprised to see that 0xaff...
>> which is the 10TiB range is accessible (44 bits) and the 64 TiB may not be.
>> I am keen to know if the system works or is it just the game that is sluggiesh?
>> Does graphics work in general, do other games work?
>>
>> The arch/x86/mm code assumes we have 46 or 52 bits of physically addressable
>> bits. There are experts who can correct me if I missed anything in my
>> analysis.
>>
>> It seems like kaslr has been hiding the issue that exists on your laptop.
>>
>> Balbir
>>
>> PS: We could try some other experiments once we have the full dmesg and also get
>> help from other experts.
>
> According to /proc/cpuinfo my CPU has 48 phsical address bits:
Thanks, that is helpful
Looking at /proc/iomem
fc00000000-fe0fffffff : PCI Bus 0000:03
fc00000000-fdffffffff : 0000:03:00.0
fe00000000-fe0fffffff : 0000:03:00.0
This makes sense and matches the BAR address ranges in the
lspci output
...
3ffe00000000-3fffffffffff : 0000:03:00.0
is interesting
Anyway, I think the nokaslr result is interesting, it seems like with nokaslr
even the older kernels have problems with the game
Could you confirm if with nokaslr
1. Only one single game stellaris is not working?
2. The entire laptop does not work?
3. Laptop works and other games work? Just one game is not working as expected?
Balbir Singh
next prev parent reply other threads:[~2025-03-13 11:47 UTC|newest]
Thread overview: 60+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-03-10 11:22 Bert Karwatzki
2025-03-10 21:48 ` Balbir Singh
2025-03-11 7:19 ` Balbir Singh
2025-03-11 7:28 ` Ingo Molnar
2025-03-11 11:15 ` Bert Karwatzki
2025-03-11 18:24 ` Bert Karwatzki
2025-03-11 22:10 ` Balbir Singh
2025-03-11 23:09 ` Bert Karwatzki
2025-03-12 0:26 ` Bert Karwatzki
2025-03-12 2:23 ` Balbir Singh
2025-03-12 1:24 ` Balbir Singh
2025-03-13 9:22 ` Bert Karwatzki
2025-03-13 10:40 ` Balbir Singh
2025-03-13 10:53 ` Bert Karwatzki
2025-03-13 11:47 ` Balbir Singh [this message]
2025-03-13 18:12 ` Bert Karwatzki
2025-03-13 21:54 ` Balbir Singh
2025-03-13 22:22 ` Bert Karwatzki
2025-03-14 6:14 ` Balbir Singh
2025-03-14 13:34 ` Balbir Singh
2025-03-14 14:18 ` Bert Karwatzki
2025-03-15 0:16 ` Balbir Singh
2025-03-15 17:40 ` Alex Deucher
2025-03-16 13:09 ` Bert Karwatzki
2025-03-16 20:06 ` Bert Karwatzki
2025-03-17 9:13 ` Balbir Singh
2025-03-20 9:01 ` Ingo Molnar
2025-03-20 23:55 ` Balbir Singh
2025-03-21 10:24 ` Ingo Molnar
2025-03-21 11:05 ` Balbir Singh
2025-03-22 8:04 ` Ingo Molnar
2025-03-22 9:40 ` Balbir Singh
2025-03-20 23:43 ` Bert Karwatzki
2025-03-21 4:55 ` Balbir Singh
2025-03-21 12:26 ` Bert Karwatzki
2025-03-22 2:06 ` Balbir Singh
2025-03-22 12:23 Bert Karwatzki
2025-03-23 6:51 ` Balbir Singh
2025-03-24 11:23 ` Bert Karwatzki
2025-03-24 12:14 ` Christian König
2025-03-24 22:48 ` Balbir Singh
[not found] ` <938c2cbd-c47f-4925-ba82-94eef54d9ebc@amd.com>
2025-03-25 22:45 ` Balbir Singh
2025-03-25 23:21 ` Bert Karwatzki
2025-03-25 23:43 ` Balbir Singh
2025-03-26 1:50 ` Balbir Singh
2025-03-26 10:10 ` Bert Karwatzki
2025-03-26 10:36 ` Balbir Singh
2025-03-26 11:14 ` Bert Karwatzki
2025-03-27 10:53 ` Ingo Molnar
2025-03-27 22:03 ` Balbir Singh
2025-03-24 21:43 ` Balbir Singh
2025-03-24 23:07 Bert Karwatzki
[not found] ` <634e77d7-4f3c-4d1a-8aa3-1978896f9bf2@amd.com>
2025-03-25 10:25 ` Balbir Singh
2025-03-25 10:14 Bert Karwatzki
2025-03-25 12:23 ` Christian König
2025-03-26 22:00 ` Bert Karwatzki
2025-03-26 22:58 ` Linus Torvalds
2025-03-27 0:57 ` Balbir Singh
2025-03-27 0:58 ` Bert Karwatzki
2025-03-27 10:40 ` Ingo Molnar
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=c7bb0bd1-529d-466d-9cce-abbac4b480ab@nvidia.com \
--to=balbirs@nvidia.com \
--cc=bhelgaas@google.com \
--cc=kees@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=luto@kernel.org \
--cc=mingo@kernel.org \
--cc=peterz@infradead.org \
--cc=spasswolf@web.de \
--cc=torvalds@linux-foundation.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®