* sja1000p_enable_configuration - enable chip configuration mode
* @chip: pointer to chip state structure
*/
-int sja1000p_enable_configuration(struct chip_t *chip)
+int sja1000p_enable_configuration(struct canchip_t *chip)
{
int i=0;
enum sja1000_PeliCAN_MOD flags;
* sja1000p_disable_configuration - disable chip configuration mode
* @chip: pointer to chip state structure
*/
-int sja1000p_disable_configuration(struct chip_t *chip)
+int sja1000p_disable_configuration(struct canchip_t *chip)
{
int i=0;
enum sja1000_PeliCAN_MOD flags;
* Return Value: negative value reports error.
* File: src/sja1000p.c
*/
-int sja1000p_chip_config(struct chip_t *chip)
+int sja1000p_chip_config(struct canchip_t *chip)
{
int i;
unsigned char n, r;
* Return Value: negative value reports error.
* File: src/sja1000p.c
*/
-int sja1000p_extended_mask(struct chip_t *chip, unsigned long code, unsigned long mask)
+int sja1000p_extended_mask(struct canchip_t *chip, unsigned long code, unsigned long mask)
{
int i;
* Return Value: negative value reports error.
* File: src/sja1000p.c
*/
-int sja1000p_baud_rate(struct chip_t *chip, int rate, int clock, int sjw,
+int sja1000p_baud_rate(struct canchip_t *chip, int rate, int clock, int sjw,
int sampl_pt, int flags)
{
int best_error = 1000000000, error;
*
* File: src/sja1000p.c
*/
-void sja1000p_read(struct chip_t *chip, struct msgobj_t *obj) {
+void sja1000p_read(struct canchip_t *chip, struct msgobj_t *obj) {
int i, flags, len, datastart;
do {
flags = can_read_reg(chip,SJAFRM);
* Positive value indicates immediate reception of message.
* File: src/sja1000p.c
*/
-int sja1000p_pre_read_config(struct chip_t *chip, struct msgobj_t *obj)
+int sja1000p_pre_read_config(struct canchip_t *chip, struct msgobj_t *obj)
{
int status;
status=can_read_reg(chip,SJASR);
* Return Value: negative value reports error.
* File: src/sja1000p.c
*/
-int sja1000p_pre_write_config(struct chip_t *chip, struct msgobj_t *obj,
+int sja1000p_pre_write_config(struct canchip_t *chip, struct msgobj_t *obj,
struct canmsg_t *msg)
{
int i=0;
* Return Value: negative value reports error.
* File: src/sja1000p.c
*/
-int sja1000p_send_msg(struct chip_t *chip, struct msgobj_t *obj,
+int sja1000p_send_msg(struct canchip_t *chip, struct msgobj_t *obj,
struct canmsg_t *msg)
{
can_write_reg(chip, sjaCMR_TR, SJACMR);
* Zero value indicates finishing of all issued transmission requests.
* File: src/sja1000p.c
*/
-int sja1000p_check_tx_stat(struct chip_t *chip)
+int sja1000p_check_tx_stat(struct canchip_t *chip)
{
if (can_read_reg(chip,SJASR) & sjaSR_TCS)
return 0;
* Return Value: negative value reports error.
* File: src/sja1000p.c
*/
-int sja1000p_set_btregs(struct chip_t *chip, unsigned short btr0,
+int sja1000p_set_btregs(struct canchip_t *chip, unsigned short btr0,
unsigned short btr1)
{
if (sja1000p_enable_configuration(chip))
* Return Value: negative value reports error.
* File: src/sja1000p.c
*/
-int sja1000p_start_chip(struct chip_t *chip)
+int sja1000p_start_chip(struct canchip_t *chip)
{
enum sja1000_PeliCAN_MOD flags;
* Return Value: negative value reports error.
* File: src/sja1000p.c
*/
-int sja1000p_stop_chip(struct chip_t *chip)
+int sja1000p_stop_chip(struct canchip_t *chip)
{
enum sja1000_PeliCAN_MOD flags;
* Return Value: negative value reports error.
* File: src/sja1000p.c
*/
-int sja1000p_remote_request(struct chip_t *chip, struct msgobj_t *obj)
+int sja1000p_remote_request(struct canchip_t *chip, struct msgobj_t *obj)
{
CANMSG("sja1000p_remote_request not implemented\n");
return -ENOSYS;
* Return Value: negative value reports error.
* File: src/sja1000p.c
*/
-int sja1000p_standard_mask(struct chip_t *chip, unsigned short code,
+int sja1000p_standard_mask(struct canchip_t *chip, unsigned short code,
unsigned short mask)
{
CANMSG("sja1000p_standard_mask not implemented\n");
* Return Value: negative value reports error.
* File: src/sja1000p.c
*/
-int sja1000p_clear_objects(struct chip_t *chip)
+int sja1000p_clear_objects(struct canchip_t *chip)
{
CANMSG("sja1000p_clear_objects not implemented\n");
return -ENOSYS;
* Return Value: negative value reports error.
* File: src/sja1000p.c
*/
-int sja1000p_config_irqs(struct chip_t *chip, short irqs)
+int sja1000p_config_irqs(struct canchip_t *chip, short irqs)
{
CANMSG("sja1000p_config_irqs not implemented\n");
return -ENOSYS;
* sja1000p_irq_write_handler() for transmit events.
* File: src/sja1000p.c
*/
-void sja1000p_irq_write_handler(struct chip_t *chip, struct msgobj_t *obj)
+void sja1000p_irq_write_handler(struct canchip_t *chip, struct msgobj_t *obj)
{
int cmd;
* @irq: interrupt vector number, this value is system specific
* @dev_id: driver private pointer registered at time of request_irq() call.
* The CAN driver uses this pointer to store relationship of interrupt
- * to chip state structure - @struct chip_t
+ * to chip state structure - @struct canchip_t
* @regs: system dependent value pointing to registers stored in exception frame
*
* Interrupt handler is activated when state of CAN controller chip changes,
* message queues.
* File: src/sja1000p.c
*/
-int sja1000p_irq_handler(int irq, struct chip_t *chip)
+int sja1000p_irq_handler(int irq, struct canchip_t *chip)
{
int irq_register, status, error_code;
struct msgobj_t *obj=chip->msgobj[0];
* Return Value: negative value reports error.
* File: src/sja1000p.c
*/
-int sja1000p_wakeup_tx(struct chip_t *chip, struct msgobj_t *obj)
+int sja1000p_wakeup_tx(struct canchip_t *chip, struct msgobj_t *obj)
{
can_preempt_disable();
*
* Return Value: returns negative number in the case of fail
*/
-int sja1000p_fill_chipspecops(struct chip_t *chip)
+int sja1000p_fill_chipspecops(struct canchip_t *chip)
{
chip->chip_type="sja1000p";
chip->max_objects=1;