HomeFreeBSD

cp2112: a number of cleanups and improvements

Description

cp2112: a number of cleanups and improvements

  • hoist all request / response structures from function level to top level
  • replace magic numeric literals with constants
  • regroup types, data and functions
  • remove setting of the id field in responses as they are completely overwritten with data from the device
  • centralize setting of the id field as it is always set to the value of request type
  • fix setting and querying of open-drain vs push-pull configuration of an output pin -- it's always in one of those configurations
  • detect special pin configurations: a pin in a special configuration is neither general purpose input or output
  • there is still no support for setting special configurations

MFC after: 2 weeks

Details

Provenance
avgAuthored on
Parents
rS364142: MFC r363907: environ(7): Update the description and include some more…
Branches
Unknown
Tags
Unknown