Ignore:
Timestamp:
2017-10-05T19:09:34Z (7 years ago)
Author:
Jiri Svoboda <jiri@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
82cbf8c6
Parents:
84eb4edd (diff), c188c62 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

Merge CUDA DDF conversion.

File:
1 moved

Legend:

Unmodified
Added
Removed
  • uspace/drv/bus/adb/cuda_adb/cuda_adb.h

    r84eb4edd r81b9d3e  
    3737#define CUDA_ADB_H_
    3838
     39#include <adt/list.h>
    3940#include <async.h>
     41#include <ddf/driver.h>
    4042#include <fibril_synch.h>
    41 #include <stddef.h>
     43#include <loc.h>
    4244#include <stdint.h>
    4345#include "cuda_hw.h"
     
    5658
    5759typedef struct {
    58         service_id_t service_id;
     60        uintptr_t base;
     61        int irq;
     62} cuda_res_t;
     63
     64/** ADB bus device */
     65typedef struct {
     66        ddf_fun_t *fun;
    5967        async_sess_t *client_sess;
     68        link_t lcuda;
     69        struct cuda *cuda;
    6070} adb_dev_t;
    6171
    62 typedef struct {
    63         struct cuda *regs;
    64         uintptr_t cuda_physical;
     72/** CUDA ADB bus */
     73typedef struct cude {
     74        struct cuda_regs *regs;
     75        uintptr_t phys_base;
     76        ddf_dev_t *dev;
    6577
    6678        uint8_t rcv_buf[CUDA_RCV_BUF_SIZE];
     
    7183        fibril_mutex_t dev_lock;
    7284
    73         adb_dev_t adb_dev[ADB_MAX_ADDR];
    74 } cuda_instance_t;
     85        list_t devs;
     86        adb_dev_t *addr_dev[ADB_MAX_ADDR];
     87} cuda_t;
     88
     89extern int cuda_add(cuda_t *, cuda_res_t *);
     90extern int cuda_remove(cuda_t *);
     91extern int cuda_gone(cuda_t *);
    7592
    7693#endif
Note: See TracChangeset for help on using the changeset viewer.