Re: [PATCH] usb: dwc3: gadget: Correct the logic for finding last SG entry

2019-10-23 Thread Jack Pham
Hi Anurag, On Fri, Jun 07, 2019 at 09:49:59AM +0300, Felipe Balbi wrote: > Anurag Kumar Vulisha writes: > >>> The dma_map_sg() merges sg1 & sg2 memory regions into sg1- > >>>dma_address. > >>> Similarly sg3 & sg4 into sg2->dma_address, sg5 & sg6 into the > >>> sg3->dma_address and sg6 & sg8 into

RE: [PATCH] usb: dwc3: gadget: Correct the logic for finding last SG entry

2019-06-07 Thread Felipe Balbi
Hi, Anurag Kumar Vulisha writes: >>> The dma_map_sg() merges sg1 & sg2 memory regions into sg1- >>>dma_address. >>> Similarly sg3 & sg4 into sg2->dma_address, sg5 & sg6 into the >>> sg3->dma_address and sg6 & sg8 into sg4->dma_address. Here the >>memory >>> regions are merged but the page_link

RE: [PATCH] usb: dwc3: gadget: Correct the logic for finding last SG entry

2019-06-06 Thread Anurag Kumar Vulisha
Vulisha >Subject: Re: [PATCH] usb: dwc3: gadget: Correct the logic for finding last SG >entry > > >Hi, > >Anurag Kumar Vulisha writes: >> As a process of preparing TRBs usb_gadget_map_request_by_dev() is >> called from dwc3_prepare_trbs() for mapping the r

Re: [PATCH] usb: dwc3: gadget: Correct the logic for finding last SG entry

2019-06-05 Thread Felipe Balbi
Hi, Anurag Kumar Vulisha writes: > As a process of preparing TRBs usb_gadget_map_request_by_dev() is > called from dwc3_prepare_trbs() for mapping the request. This will > call dma_map_sg() if req->num_sgs are greater than 0. dma_map_sg() > will map the sg entries in sglist and return the

[PATCH] usb: dwc3: gadget: Correct the logic for finding last SG entry

2019-05-29 Thread Anurag Kumar Vulisha
As a process of preparing TRBs usb_gadget_map_request_by_dev() is called from dwc3_prepare_trbs() for mapping the request. This will call dma_map_sg() if req->num_sgs are greater than 0. dma_map_sg() will map the sg entries in sglist and return the number of mapped SGs. As a part of mapping, some