Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 22 Oct 2012 20:05:52 -0700
From:      matt <sendtomatt@gmail.com>
To:        Justin Hibbits <chmeeedalf@gmail.com>
Cc:        freebsd-x11@freebsd.org, freebsd-ppc@freebsd.org
Subject:   Re: Does drm/dri currently work on PPC?
Message-ID:  <50860990.7020204@gmail.com>
In-Reply-To: <20121022215945.436873dc@narn.knownspace>
References:  <5083C719.1040109@gmail.com> <CAKLtBChswXj7HcZeC=SaJgMNDrZXu==DHFP5PW4wB9=ruKSWWA@mail.gmail.com> <20121021092136.20307802@narn.knownspace> <50846392.70007@gmail.com> <CAHSQbTC7SA8qiVGQi%2BfmsmzYBVQLR09Dmzhjk1Ev=srsufc_HQ@mail.gmail.com> <5085F595.4050609@gmail.com> <20121022215945.436873dc@narn.knownspace>

next in thread | previous in thread | raw e-mail | index | archive | help
On 10/22/12 18:59, Justin Hibbits wrote:
> On Mon, 22 Oct 2012 18:40:37 -0700
> matt <sendtomatt@gmail.com> wrote:
>
>> On 10/22/12 10:27, Justin Hibbits wrote:
>>> On Sun, Oct 21, 2012 at 5:05 PM, matt <sendtomatt@gmail.com
>>> <mailto:sendtomatt@gmail.com>> wrote:
>>>
>>>     On 10/21/12 06:21, Justin Hibbits wrote:
>>>     > On Sun, 21 Oct 2012 06:09:23 -0400
>>>     > Michael Copeland <michael@kryptos-security.com
>>>     <mailto:michael@kryptos-security.com>> wrote:
>>>     >
>>>     >> On Sun, Oct 21, 2012 at 5:57 AM, matt <sendtomatt@gmail.com
>>>     <mailto:sendtomatt@gmail.com>> wrote:
>>>     >>
>>>     >>> Do we have working drm/dri for radeon on PowerPC?
>>>     >>>
>>>     >>> I saw some old stuff that implied it, and a recent-ish PR.
>>>     >>>
>>>     >>> Anyone have this working? Or did it work once?
>>>     >>>
>>>     >>> Matt
>>>     >>> _______________________________________________
>>>     >>> freebsd-ppc@freebsd.org <mailto:freebsd-ppc@freebsd.org>
>>>     mailing list
>>>     >>> http://lists.freebsd.org/mailman/listinfo/freebsd-ppc
>>>     >>> To unsubscribe, send any mail to
>>>     >>> "freebsd-ppc-unsubscribe@freebsd.org
>>>     <mailto:freebsd-ppc-unsubscribe@freebsd.org>"
>>>     >>>
>>>     >> Seems fine on a mini g4 with radeon 9200.
>>>     >> _______________________________________________
>>>     >> freebsd-ppc@freebsd.org <mailto:freebsd-ppc@freebsd.org>
>>>     mailing list
>>>     >> http://lists.freebsd.org/mailman/listinfo/freebsd-ppc
>>>     >> To unsubscribe, send any mail to
>>>     "freebsd-ppc-unsubscribe@freebsd.org
>>>     <mailto:freebsd-ppc-unsubscribe@freebsd.org>"
>>>     > Haven't had any luck on a G4 tower with radeon9600, but last
>>>     > I tried was over a year ago.  Best I can say is try it :)
>>>     >
>>>     > - Justin
>>>     >
>>>     Thanks, I'll give it a try (g4 mdd/radeon 9000). I might be
>>> compiling for a bit, but I'll send any results.
>>>
>>>     Matt
>>>
>>>
>>> Remember, sys/modules/drm is not built by default for PowerPC, so
>>> you'll have to manually build those.  I don't know what else is
>>> needed.
>>>
>>> - Justin
>> I am running CURRENT based on yesterday evening's CVS.
>> I built the drm modules:
>>  cd /usr/src/sys/modules/drm && make && make install
>> This required setting NO_WERROR= and WERROR= in the makefiles for
>> radeon and r128. The errors are "value computed is not used".
>> The second fix required to get it to build was to make sure LINUX_DRM
>> gets undefined, this may result from my build process, but the undef
>> is ifdef'd for amd64.
>>
>> After the module is built "successfully" and installed, kldloading it
>> doesn't do anything, no drm0 created.
>> kldload radeon.ko creates a drm0, but Xorg immediately crashes when
>> loading the radeon driver, bringing down the entire system.
>>
>> I assume there is some endian-unsafe stuff in radeon and drm maybe?
>> My system is an AGP Radeon r200 on an MDD G4.
>>
>> Any ideas or anything I can do to help?
>>
>> Matt
> You're exactly where I was when I last tried.  I didn't have the
> patience to look into it.  I did read today, though, that NetBSD has
> working drm on PowerPC, so you can do some diffing with that codebase,
> or even try NetBSD on a spare partition to confirm.  Beyond that, some
> ddb magic could help track down where the problem lies -- firewire
> cable and a spare machine come in quite handy for this type of thing,
> with dcons.  Even getting a backtrace would be a good start to tracking
> down the bugs.
>
> DRM is something I want to get working on PowerPC, but it's low on my
> list (only so many hours in a day unfortunately), so I'm glad somebody
> is looking :)
>
> - Justin
>
I tried OpenBSD. They have drm, but no working agp yet. A couple lockups
under X thrashed the filesystem and I was over it. The sources for
macppc are in transition or something and weren't building for me a week
or so ago.
NetBSD is probably worth another shot, I started out on MacBSD when it
was new.
Luckily I have a collection of IDE disks to swap, so it should be
painless as far as not having to wipe one for the other.

My guess is that we're talking to the card in big endian, because our
drivers probably assume the host is little endian like pci. If that's
the problem, fixes here will probably apply for sparc and arm (and
anything else with non little-endian modes).
This is armchair conjecture of course.

My amd64 box has firewire, although I've yet to use DDB over firewire.
Sounds like fun, so I'll try to work on getting a backtrace.
Only so many hours indeed.

Matt




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?50860990.7020204>