graphics on amd radeon vega

Michael Schuster michaelsprivate at gmail.com
Wed Dec 30 19:53:01 UTC 2020


On Wed, Dec 30, 2020 at 3:41 PM Michael Schuster <michaelsprivate at gmail.com>
wrote:

>
>
> On Wed, Dec 30, 2020 at 2:54 PM Vasily Postnicov <shamaz.mazum at gmail.com>
> wrote:
>
>> Cannot say for sure where you need to place that. Its either
>> /boot/loader.conf or /etc/sysctl.conf
>>
>> The second sets sysctls later in the boot process. And it can not set
>> tunables, of course.
>>
>> I suggest you figure it yourself)
>>
>
> will do, many thanks!
> Michael
>
>>
>> ср, 30 дек. 2020 г., 16:25 Michael Schuster <michaelsprivate at gmail.com>:
>>
>>>
>>>
>>> On Wed, Dec 30, 2020 at 2:01 PM Vasily Postnicov <shamaz.mazum at gmail.com>
>>> wrote:
>>>
>>>> Does sysctl -a | grep exp_hw_support show anything?
>>>>
>>>
>>> indeed it does:
>>> $ sysctl -a | grep exp_hw_support
>>> hw.amdgpu.exp_hw_support: 0
>>> compat.linuxkpi.amdgpu_exp_hw_support: 0
>>> $
>>>
>>>> Usual way to tweak kernel parameters is via sysctl.
>>>>
>>>
I set hw.amdgpu.exp_hw_support="1" in /boot/loader.conf, which seemed to
work, because I now see messages like this in /var/log/messages:

Dec 30 20:02:10 hbeast kernel: amdgpu: [powerplay] smu driver if version =
0x0000000a, smu fw if version = 0x0000000e, smu fw version = 0x00373800
(55.56.0)
Dec 30 20:02:10 hbeast kernel: amdgpu: [powerplay] SMU driver if version
not matched
Dec 30 20:02:10 hbeast kernel: amdgpu: [powerplay] dpm has been disabled
Dec 30 20:02:10 hbeast kernel: amdgpu: [powerplay] SMU is initialized
successfully!
Dec 30 20:02:10 hbeast kernel: [drm] VCN decode and encode initialized
successfully(under DPG Mode).
Dec 30 20:02:10 hbeast kernel: drmn0: ring gfx uses VM inv eng 0 on hub 0
Dec 30 20:02:10 hbeast kernel: drmn0: ring comp_1.0.0 uses VM inv eng 1 on
hub 0
[...]
Dec 30 20:02:10 hbeast kernel: drmn0: ring vcn_jpeg uses VM inv eng 6 on
hub 1
Dec 30 20:02:10 hbeast kernel: [drm] Initialized amdgpu 3.35.0 20150101 for
drmn0 on minor 0

which seems an improvement over before, though every invocation of "sysctl
-a" causes a crash dump with this stack:

(kgdb) bt
#0  0xffffffff80c14083 in sched_switch ()
#1  0xffffffff80bf0635 in mi_switch ()
#2  0xffffffff80c3fe69 in sleepq_switch ()
#3  0xffffffff80c40246 in sleepq_catch_signals ()
#4  0xffffffff80c3ffa9 in sleepq_wait_sig ()
#5  0xffffffff80befb4a in _sleep ()
#6  0xffffffff80c5a3fa in pipe_read ()
#7  0xffffffff80c56fc1 in dofileread ()
#8  0xffffffff80c56b3c in sys_read ()
#9  0xffffffff81035fde in amd64_syscall ()
#10 <signal handler called>
#11 0x000000080039ee6a in ?? ()

... so I reverted (or rather, returned to the previous build environment).

cheers & thx
Michael


>>> from looking at other settings, I would guess I need to put this in
>>> /boot/loader.conf to make this persistent across reboot ... correct?
>>> (again, sorry if that's an FAQ - feel free to point me to documentation
>>> about this)
>>>
>>>> But this is linux stuff so it can be anything else.
>>>>
>>>> If sysctl does not help, you can recompile the whole driver changing
>>>> int amdgpu_exp_hw_support = 0;
>>>> to
>>>> int amdgpu_exp_hw_support = 1;
>>>> in drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c
>>>>
>>>
>>> I already found that, though I wanted to keep that as a very last resort
>>> :-)
>>>
>>> thx
>>> Michael
>>>
>>>>
>>>> ср, 30 дек. 2020 г., 15:17 Michael Schuster <michaelsprivate at gmail.com
>>>> >:
>>>>
>>>>> On Tue, Dec 29, 2020 at 3:35 PM Oskar Sharipov <oskarsh at riseup.net>
>>>>> wrote:
>>>>>
>>>>> > On Tue, Dec 29, 2020 at 05:04:38PM +0300, Vasily Postnicov wrote:
>>>>> > > 13-CURRENT supports that chip. See
>>>>> > >
>>>>> >
>>>>> https://github.com/freebsd/drm-kmod/blob/drm_v5.4.62_4/drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c
>>>>> > >
>>>>> > > > {0x1002, 0x15d8, PCI_ANY_ID, PCI_ANY_ID, 0, 0,
>>>>> CHIP_RAVEN|AMD_IS_APU}
>>>>> >
>>>>> > Oh, wow. Then I will consider could I try CURRENT now or wait
>>>>> > until it released. Thank you!
>>>>> >
>>>>>
>>>>> when I Install this version on current as of today, I see this in
>>>>> /var/log/messages:
>>>>>
>>>>> Dec 30 13:11:56 hbeast kernel: [drm] amdgpu kernel modesetting enabled.
>>>>> Dec 30 13:11:56 hbeast kernel: drmn0: <drmn> on vgapci0
>>>>> Dec 30 13:11:56 hbeast kernel: [drm] This hardware requires
>>>>> experimental
>>>>> hardware support.
>>>>> Dec 30 13:11:56 hbeast kernel: See modparam exp_hw_support
>>>>> Dec 30 13:11:56 hbeast kernel: device_attach: drmn0 attach returned 19
>>>>> sorry if this is an FAQ, but I couldn't find an answer: how do I
>>>>> enable/modify "modparam exp_hw_support"?
>>>>>
>>>>> thx
>>>>> Michael
>>>>>
>>>>> --
>>>>>
>>>> --
Michael Schuster
http://recursiveramblings.wordpress.com/
recursion, n: see 'recursion'


More information about the freebsd-questions mailing list