lkml.org 
[lkml]   [2015]   [Mar]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: Possible no longer required cast in the function,usbhs_parse_dt in common.c
On Tue, Mar 17, 2015 at 12:10:41AM -0400, nick wrote:
>
>
> On 2015-03-16 11:56 PM, nick wrote:
> >
> >
> > On 2015-03-16 11:54 PM, Felipe Balbi wrote:
> >> On Mon, Mar 16, 2015 at 11:51:15PM -0400, nick wrote:
> >>>
> >>>
> >>> On 2015-03-16 11:37 PM, Peter Chen wrote:
> >>>>
> >>>>>
> >>>>> Greetings All,
> >>>>> I have been getting the below build warnings:
> >>>>> drivers/usb/renesas_usbhs/common.c: In function ‘usbhs_parse_dt’:
> >>>>> drivers/usb/renesas_usbhs/common.c:482:25: warning: cast from pointer to
> >>>>> integer of different size [-Wpointer-to-int-cast]
> >>>>> dparam->type = of_id ? (u32)of_id->data : 0;
> >>>>> After looking into the function I am curious if the hardware is only 32 bit as if
> >>>>> the supported hardware for this driver is then this cast is no longer required
> >>>>> and I can send in a patch removing it. Furthermore, sorry for the simple
> >>>>> question but I don't have access to the device specs for supported hardware
> >>>>> so I though it would be better to ask before I send in patch fixing this issue.
> >>>>> Thanks,
> >>>>> Nick
> >>>>
> >>>> Patch is welcome, there will be comment if it is not suitable.
> >>>>
> >>>> Peter
> >>>>
> >>> I understand that,my question was does the hardware for this driver support 64 bit.
> >>
> >> regardless, it shouldn't produce a build warning.
> >>
> > It does for me.
> > Nick
> >
> After looking more closely it seems me are trying to convert a const
> void to a int. Does the data member need to be const as this may be
> causing the issue.

why would const have anything to do with sizes ?

--
balbi
[unhandled content-type:application/pgp-signature]
\
 
 \ /
  Last update: 2015-03-17 05:21    [W:0.071 / U:0.060 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site