]> rtime.felk.cvut.cz Git - lincan.git/blobdiff - lincan/include/main.h
Added attach_to_chip() and release_chip() functions for each chip.
[lincan.git] / lincan / include / main.h
index e05e774fb6a3bfb94d69dcde35be1ca61b9fcb19..f7afa85a46fc0eab7f04204115207f68288f8322 100644 (file)
@@ -320,6 +320,8 @@ struct hwspecops_t {
  * @enable_configuration: enable chip configuration mode
  * @disable_configuration: disable chip configuration mode
  * @set_btregs: configures bitrate registers
+ * @attach_to_chip: attaches to the chip, setups registers and possibly state informations
+ * @release_chip: called before chip structure removal if %CHIP_ATTACHED is set
  * @start_chip: starts chip message processing
  * @stop_chip: stops chip message processing
  * @irq_handler: interrupt service routine
@@ -350,6 +352,8 @@ struct chipspecops_t {
        int (*disable_configuration)(struct canchip_t *chip);
        int (*set_btregs)(struct canchip_t *chip, unsigned short btr0, 
                                                        unsigned short btr1);
+       int (*attach_to_chip)(struct canchip_t *chip);
+       int (*release_chip)(struct canchip_t *chip);
        int (*start_chip)(struct canchip_t *chip);
        int (*stop_chip)(struct canchip_t *chip);
        int (*irq_handler)(int irq, struct canchip_t *chip);