[U-Boot-Users] usb_ohci.c: warning: dereferencing type-punned pointer will break strict-aliasing rules

Wolfgang Denk wd at denx.de
Sun Apr 20 08:36:47 CEST 2008


Hello Markus,

the OHCI driver code is still emitting lots of warning messages:

usb_ohci.c: In function 'roothub_a':
usb_ohci.c:156: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c:156: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c: In function 'roothub_b':
usb_ohci.c:158: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c: In function 'roothub_status':
usb_ohci.c:160: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c: In function 'sohci_return_job':
usb_ohci.c:521: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c:522: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c:524: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c:525: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c: In function 'ep_link':
usb_ohci.c:635: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c:643: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c:651: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c:659: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c: In function 'ep_unlink':
usb_ohci.c:722: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c:724: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c:739: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c:741: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c: In function 'td_submit_job':
usb_ohci.c:907: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c:923: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c: In function 'ohci_submit_rh_msg':
usb_ohci.c:1275: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c:1399: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c: In function 'hc_reset':
usb_ohci.c:1590: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c:1591: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c:1593: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c:1603: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c:1611: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c:1614: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c:1615: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c: In function 'hc_start':
usb_ohci.c:1641: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c:1642: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c:1644: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c:1647: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c:1649: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c:1650: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c:1655: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c:1661: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c:1664: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c:1667: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c:1671: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c:1673: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c: In function 'hc_interrupt':
usb_ohci.c:1706: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c:1710: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c:1743: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c:1744: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c:1746: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c:1747: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c:1752: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c:1760: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c:1762: warning: dereferencing type-punned pointer will break strict-aliasing rules
usb_ohci.c:1766: warning: dereferencing type-punned pointer will break strict-aliasing rules



Could you please have a look?

Thanks in advance.

Best regards,

Wolfgang Denk

-- 
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
Horses just naturally have mohawk haircuts.




More information about the U-Boot mailing list