You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by GitBox <gi...@apache.org> on 2021/09/27 12:22:23 UTC

[GitHub] [incubator-nuttx] spflieger opened a new issue #4618: usbhost: hid_parser.c is compiled unconditionally and is possibly dead code

spflieger opened a new issue #4618:
URL: https://github.com/apache/incubator-nuttx/issues/4618


   in [usbhost/Make.defs](https://github.com/apache/incubator-nuttx/blob/master/drivers/usbhost/Make.defs) hid_parser.c is added to CSRCS before ifeq ($(CONFIG_USBHOST),y) so it is always compiled, no matter if USB is used or not.
   It seems that the functions are not used by any code that is publicly available. 
   So just moving it inside the CONFIG_USBHOST block is probably not the right thing/fix.
   
   Maybe another config option should be added? Does anyone know where the code is used?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [incubator-nuttx] patacongo commented on issue #4618: usbhost: hid_parser.c is compiled unconditionally and is possibly dead code

Posted by GitBox <gi...@apache.org>.
patacongo commented on issue #4618:
URL: https://github.com/apache/incubator-nuttx/issues/4618#issuecomment-927934439


   It is not "dead code" in that even if it is unnecessarily compiled, it will not be linked.  So no harm done other than wasted compile time.
   
   It was moved out of the conditional logic with commit 1ba22407623cb60c54e89969c13ea2e227dff9fd in 2011 but I don't know why.  That was too long ago to reconstruct what was going on.  Perhaps it was used by other logic at some time?  Perhaps with was used by a HID device side driver (drivers/usbdev)?
   
   This is third party code that could have some value in the future.  Any complex HID driver would need this parsing logic.
   
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [incubator-nuttx] patacongo edited a comment on issue #4618: usbhost: hid_parser.c is compiled unconditionally and is possibly dead code

Posted by GitBox <gi...@apache.org>.
patacongo edited a comment on issue #4618:
URL: https://github.com/apache/incubator-nuttx/issues/4618#issuecomment-927934439


   It is not "dead code" in that even if it is unnecessarily compiled, it will not be linked.  So no harm done other than wasted compile time.
   
   It was moved out of the conditional logic with commit 1ba22407623cb60c54e89969c13ea2e227dff9fd in 2011 but I don't know why.  That was too long ago to reconstruct what was going on.  Perhaps it was used by other logic at some time?  Perhaps it was used by a HID device side driver (drivers/usbdev)?  Perhaps a custom driver that is not in the repository?
   
   This is third party code that could have some value in the future.  Any complex HID driver would need this parsing logic.
   
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org