[DRIVER UPDATE] aty128fb

Jes Sorensen Jes.Sorensen en cern.ch
Vie Ene 28 11:08:33 CST 2000


>>>>> "Benjamin" == Benjamin Herrenschmidt <bh40 en calva.net> writes:

>> With regard to filling the cursor then that particular example is
>> not very good since opdating the cursor data is rarely a
>> performance critical item ;-) However even for the performance
>> critical cases (like printing data on the screen), you'd rather use
>> the __raw_{read,write}l() macros and explicitly add the [wm]mb()
>> macros.

Benjamin> Yep. Or you can eventually use normal memory accesses like
Benjamin> it's done usually when accessing the fb. datas for the
Benjamin> cursor pixels. In any case, you need wmb() macro between
Benjamin> filling the cursor datas and enabling it, and this is not
Benjamin> ppc-specific.

Using normal memory accesses is wrong though, it'll break miserably on
systems where the PCI memory is not mapped as regular memory in on
contigous chunk. Some of the early Alpha's have what they call sparse
memory.

This is one of the reasons why the __raw_{read,write} macros were
introduced - you should use them in this case to make the code
portable.

Jes

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo en vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/



Más información sobre la lista de distribución Ayuda