Date: Sun, 17 Jun 2018 19:24:40 +0000 (UTC) From: Dimitry Andric <dim@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r335297 - head/sys/compat/ndis Message-ID: <201806171924.w5HJOeqE085531@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: dim Date: Sun Jun 17 19:24:40 2018 New Revision: 335297 URL: https://svnweb.freebsd.org/changeset/base/335297 Log: Fix build of ndis with base gcc on i386 Casting from rman_res_t to a pointer results in "cast to pointer from integer of different size" warnings with base gcc on i386, so use an intermediate cast to uintptr_t to suppress it. In this case, the I/O port range is effectively limited to the range of 0..65535. Reviewed by: imp MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D15746 Modified: head/sys/compat/ndis/subr_ndis.c Modified: head/sys/compat/ndis/subr_ndis.c ============================================================================== --- head/sys/compat/ndis/subr_ndis.c Sun Jun 17 19:14:05 2018 (r335296) +++ head/sys/compat/ndis/subr_ndis.c Sun Jun 17 19:24:40 2018 (r335297) @@ -1287,7 +1287,7 @@ NdisMRegisterIoPortRange(offset, adapter, port, numpor if (rman_get_size(sc->ndis_res_io) < numports) return (NDIS_STATUS_INVALID_LENGTH); - *offset = (void *)rman_get_start(sc->ndis_res_io); + *offset = (void *)(uintptr_t)rman_get_start(sc->ndis_res_io); return (NDIS_STATUS_SUCCESS); }
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201806171924.w5HJOeqE085531>