Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 05 Apr 2016 23:21:32 +0000
From:      bugzilla-noreply@freebsd.org
To:        freebsd-bugs@FreeBSD.org
Subject:   [Bug 207786] gpioiic_callback() dereferences IIC "how" argument incorrectly
Message-ID:  <bug-207786-8-TyXCDUl3I4@https.bugs.freebsd.org/bugzilla/>
In-Reply-To: <bug-207786-8@https.bugs.freebsd.org/bugzilla/>
References:  <bug-207786-8@https.bugs.freebsd.org/bugzilla/>

next in thread | previous in thread | raw e-mail | index | archive | help

https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=207786

--- Comment #2 from chadf@triularity.org ---
When will anyone ever pass an address that isn't memory aligned _and_ using the
interface correctly? Any code calling that which doesn't pass the address of an
int (which should be aligned automatically) should be fixed instead of trying
to work around it here.

The only place in the sys code that seems to initiate such a callback (for
IIC_REQUEST_BUS) is iicbus_request_bus() [sys/dev/iicbus/iiconf.c], which
passes the address of an int parameter that is expected to already be aligned.

The function lpbb_callback() [sys/dev/ppbus/lpbb.c] already handles this
properly, presumable without any alignment problems.

-- 
You are receiving this mail because:
You are the assignee for the bug.


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