Thread (3 messages) 3 messages, 3 authors, 7d ago

Re: [PATCH] fbdev: pvr2fb: correct user pointer annotation and sentinel initializer

From: Uwe Kleine-König <hidden>
Date: 2026-07-18 21:57:46
Also in: dri-devel, lkml

On Mon, Jul 13, 2026 at 12:16:38PM +0200, Florian Fuchs wrote:
Add __user annotation to buf, as it is passed as a user pointer in
pin_user_pages_fast(). Use an empty initializer for the sentinel
board-table entry to avoid initializing a function pointer with an
integer literal.
FTR: Using 0 in an initializer is covered by the C standard. Anyhow, I
agree that { } is nicer.

Having said that, I think the right thing to do here is to drop the
sentinel entry, because board_driver[] is only used in for loops that
iterate between 0 (inclusive) and ARRAY_SIZE(board_driver) (exclusive).

Also I would split this patch in two.

Best regards
Uwe

Attachments

Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help