Updated TODO tags and struct hfi1_user_sdma_pkt_q
This commit is contained in:
committed by
Balazs Gerofi
parent
64e2639adc
commit
5cf884ef41
@ -93,7 +93,7 @@ struct iowait_work {
|
||||
#ifdef __HFI1_ORIG__
|
||||
struct work_struct iowork;
|
||||
#else
|
||||
//TODO:
|
||||
//TODO: iowait_work
|
||||
#endif /* __HFI1_ORIG__ */
|
||||
struct list_head tx_head;
|
||||
struct iowait *iow;
|
||||
@ -151,7 +151,7 @@ struct iowait {
|
||||
wait_queue_head_t wait_dma;
|
||||
wait_queue_head_t wait_pio;
|
||||
#else
|
||||
//TODO:
|
||||
//TODO: wait
|
||||
#endif /* __HFI1_ORIG__ */
|
||||
atomic_t sdma_busy;
|
||||
atomic_t pio_busy;
|
||||
|
||||
@ -124,20 +124,28 @@ struct hfi1_user_sdma_pkt_q {
|
||||
#ifdef __HFI1_ORIG__
|
||||
struct kmem_cache *txreq_cache;
|
||||
#else
|
||||
void *txreq_cache; //unused
|
||||
void *unused0;
|
||||
#endif /* __HFI1_ORIG__ */
|
||||
struct user_sdma_request *reqs;
|
||||
unsigned long *req_in_use;
|
||||
struct iowait busy;
|
||||
unsigned state;
|
||||
#ifdef __HFI1_ORIG__
|
||||
#ifdef __HFI1_ORIG__
|
||||
wait_queue_head_t wait;
|
||||
#else
|
||||
//TODO: hfi1_user_sdma_pkt_q
|
||||
#endif /* __HFI1_ORIG__ */
|
||||
unsigned long unpinned;
|
||||
#ifdef __HFI1_ORIG__
|
||||
struct mmu_rb_handler *handler;
|
||||
#else
|
||||
void *unused1;
|
||||
#endif /* __HFI1_ORIG__ */
|
||||
atomic_t n_locked;
|
||||
#ifdef __HFI1_ORIG__
|
||||
struct mm_struct *mm;
|
||||
#else
|
||||
//TODO:
|
||||
void *unused2;
|
||||
#endif /* __HFI1_ORIG__ */
|
||||
};
|
||||
|
||||
|
||||
@ -758,7 +758,7 @@ int hfi1_user_sdma_process_request(void *private_data, struct iovec *iovec,
|
||||
dlid = be16_to_cpu(req->hdr.lrh[1]);
|
||||
selector = dlid_to_selector(dlid);
|
||||
selector += uctxt->ctxt + fd->subctxt;
|
||||
/* TODO: check the rcu stuff */
|
||||
/* TODO: sdma_select_user_engine check the rcu stuff */
|
||||
//req->sde = sdma_select_user_engine(dd, selector, vl);
|
||||
|
||||
if (!req->sde || !sdma_running(req->sde)) {
|
||||
@ -947,7 +947,7 @@ static int user_sdma_send_pkts(struct user_sdma_request *req, unsigned maxpkts)
|
||||
set_bit(SDMA_REQ_DONE_ERROR, &req->flags);
|
||||
return -EFAULT;
|
||||
}
|
||||
|
||||
//TODO: kmem_cache_alloc
|
||||
#ifdef __HFI1_ORIG__
|
||||
tx = kmem_cache_alloc(pq->txreq_cache, GFP_KERNEL);
|
||||
#else
|
||||
@ -1600,7 +1600,7 @@ static inline void pq_update(struct hfi1_user_sdma_pkt_q *pq)
|
||||
{
|
||||
if (atomic_dec_and_test(&pq->n_reqs)) {
|
||||
xchg(&pq->state, SDMA_PKT_Q_INACTIVE);
|
||||
//TODO: wake_up
|
||||
//TODO: pq_update wake_up
|
||||
//wake_up(&pq->wait);
|
||||
}
|
||||
}
|
||||
@ -1630,7 +1630,7 @@ static void user_sdma_free_request(struct user_sdma_request *req, bool unpin)
|
||||
if (!node)
|
||||
continue;
|
||||
|
||||
//TODO:
|
||||
//TODO: hfi1_mmu_rb_remove
|
||||
#ifdef __HFI1_ORIG__
|
||||
if (unpin)
|
||||
hfi1_mmu_rb_remove(req->pq->handler,
|
||||
|
||||
Reference in New Issue
Block a user