struct hwspecops_t

Name

struct hwspecops_t --  hardware/board specific operations

Synopsis

struct hwspecops_t {
  int (* request_io (struct candevice_t *candev);
  int (* release_io (struct candevice_t *candev);
  int (* reset (struct candevice_t *candev);
  int (* init_hw_data (struct candevice_t *candev);
  int (* init_chip_data (struct candevice_t *candev, int chipnr);
  int (* init_obj_data (struct chip_t *chip, int objnr);
  int (* program_irq (struct candevice_t *candev);
  void (* write_register (unsigned char data,unsigned long address);
  unsigned (* read_register (unsigned long address);
};  

Members

request_io

reserve io or memory range for can board

release_io

free reserved io memory range

reset

hardware reset routine

init_hw_data

called to initialize &candevice_t structure, mainly res_add, nr_all_chips, nr_82527_chips, nr_sja1000_chips and flags fields

init_chip_data

called initialize each &chip_t structure, mainly chip_type, chip_base_addr, clock and chip specific registers. It is responsible to setup &chip_t->chipspecops functions for non-standard chip types (type other than "i82527", "sja1000" or "sja1000p")

init_obj_data

called initialize each &msgobj_t structure, mainly obj_base_addr field.

program_irq

program interrupt generation hardware of the board if flag PROGRAMMABLE_IRQ is present for specified device/board

write_register

low level write register routine

read_register

low level read register routine