Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

dma: ipu_idmac driver cosmetic clean-up

Remove superfluous semicolons, update comments.

Signed-off-by: Guennadi Liakhovetski <lg@denx.de>
Signed-off-by: Dan Williams <dan.j.williams@intel.com>

authored by

Guennadi Liakhovetski and committed by
Dan Williams
0149f7d5 257b17ca

+14 -19
+14 -19
drivers/dma/ipu/ipu_idmac.c
··· 107 107 } 108 108 } 109 109 110 - /* Enable / disable direct write to memory by the Camera Sensor Interface */ 110 + /* Enable direct write to memory by the Camera Sensor Interface */ 111 111 static void ipu_ic_enable_task(struct ipu *ipu, enum ipu_channel channel) 112 112 { 113 113 uint32_t ic_conf, mask; ··· 126 126 idmac_write_icreg(ipu, ic_conf, IC_CONF); 127 127 } 128 128 129 + /* Called under spin_lock_irqsave(&ipu_data.lock) */ 129 130 static void ipu_ic_disable_task(struct ipu *ipu, enum ipu_channel channel) 130 131 { 131 132 uint32_t ic_conf, mask; ··· 423 422 break; 424 423 default: 425 424 dev_err(ipu_data.dev, 426 - "mxc ipu: unimplemented pixel format %d\n", pixel_fmt); 425 + "mx3 ipu: unimplemented pixel format %d\n", pixel_fmt); 427 426 break; 428 427 } 429 428 ··· 434 433 uint16_t burst_pixels) 435 434 { 436 435 params->pp.npb = burst_pixels - 1; 437 - }; 436 + } 438 437 439 438 static void ipu_ch_param_set_buffer(union chan_param_mem *params, 440 439 dma_addr_t buf0, dma_addr_t buf1) 441 440 { 442 441 params->pp.eba0 = buf0; 443 442 params->pp.eba1 = buf1; 444 - }; 443 + } 445 444 446 445 static void ipu_ch_param_set_rotation(union chan_param_mem *params, 447 446 enum ipu_rotate_mode rotate) 448 447 { 449 448 params->pp.bam = rotate; 450 - }; 449 + } 451 450 452 451 static void ipu_write_param_mem(uint32_t addr, uint32_t *data, 453 452 uint32_t num_words) ··· 572 571 { 573 572 /* Channel Parameter Memory */ 574 573 return 0x10000 | (dma_ch << 4); 575 - }; 574 + } 576 575 577 576 static void ipu_channel_set_priority(struct ipu *ipu, enum ipu_channel channel, 578 577 bool prio) ··· 612 611 613 612 /** 614 613 * ipu_enable_channel() - enable an IPU channel. 615 - * @channel: channel ID. 614 + * @idmac: IPU DMAC context. 615 + * @ichan: IDMAC channel. 616 616 * @return: 0 on success or negative error code on failure. 617 617 */ 618 618 static int ipu_enable_channel(struct idmac *idmac, struct idmac_channel *ichan) ··· 651 649 652 650 /** 653 651 * ipu_init_channel_buffer() - initialize a buffer for logical IPU channel. 654 - * @channel: channel ID. 652 + * @ichan: IDMAC channel. 655 653 * @pixel_fmt: pixel format of buffer. Pixel format is a FOURCC ASCII code. 656 654 * @width: width of buffer in pixels. 657 655 * @height: height of buffer in pixels. ··· 689 687 } 690 688 691 689 /* IC channel's stride must be a multiple of 8 pixels */ 692 - if ((channel <= 13) && (stride % 8)) { 690 + if ((channel <= IDMAC_IC_13) && (stride % 8)) { 693 691 dev_err(ipu->dev, "Stride must be 8 pixel multiple\n"); 694 692 return -EINVAL; 695 693 } ··· 754 752 755 753 /** 756 754 * ipu_update_channel_buffer() - update physical address of a channel buffer. 757 - * @channel: channel ID. 755 + * @ichan: IDMAC channel. 758 756 * @buffer_n: buffer number to update. 759 757 * 0 or 1 are the only valid values. 760 758 * @phyaddr: buffer physical address. ··· 1343 1341 } 1344 1342 } 1345 1343 1346 - /* 1347 - * At the time .device_alloc_chan_resources() method is called, we cannot know, 1348 - * whether the client will accept the channel. Thus we must only check, if we 1349 - * can satisfy client's request but the only real criterion to verify, whether 1350 - * the client has accepted our offer is the client_count. That's why we have to 1351 - * perform the rest of our allocation tasks on the first call to this function. 1352 - */ 1344 + /* Allocate and initialise a transfer descriptor. */ 1353 1345 static struct dma_async_tx_descriptor *idmac_prep_slave_sg(struct dma_chan *chan, 1354 1346 struct scatterlist *sgl, unsigned int sg_len, 1355 1347 enum dma_data_direction direction, unsigned long tx_flags) ··· 1428 1432 struct idmac_tx_desc *desc = ichan->desc + i; 1429 1433 if (list_empty(&desc->list)) 1430 1434 /* Descriptor was prepared, but not submitted */ 1431 - list_add(&desc->list, 1432 - &ichan->free_list); 1435 + list_add(&desc->list, &ichan->free_list); 1433 1436 1434 1437 async_tx_clear_ack(&desc->txd); 1435 1438 }