[gpio:gpio-descriptors-spi 14/14] drivers/spi/spi-pl022.c:451:27: error: no member named 'cur_cs' in 'struct pl022'; did you mean 'cur_msg'?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



tree:   https://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-gpio.git gpio-descriptors-spi
head:   d52781e8bf3600398a5da184d4df22072a8e5e57
commit: d52781e8bf3600398a5da184d4df22072a8e5e57 [14/14] slask
config: arm64-defconfig (attached as .config)
compiler: clang version 9.0.0 (git://gitmirror/llvm_project fee855b5bc1abe1f3f89e977ce4c81cf9bdbc2e4)
reproduce:
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        git checkout d52781e8bf3600398a5da184d4df22072a8e5e57
        # save the attached .config to linux build tree
        make.cross ARCH=arm64 

If you fix the issue, kindly add following tag
Reported-by: kbuild test robot <lkp@xxxxxxxxx>

All errors (new ones prefixed by >>):

>> drivers/spi/spi-pl022.c:451:27: error: no member named 'cur_cs' in 'struct pl022'; did you mean 'cur_msg'?
     tmp &= ~(1UL << (pl022->cur_cs));
                             ^~~~~~
                             cur_msg
   drivers/spi/spi-pl022.c:379:22: note: 'cur_msg' declared here
    struct spi_message *cur_msg;
                        ^
>> drivers/spi/spi-pl022.c:451:16: error: invalid operands to binary expression ('unsigned long' and 'struct spi_message *')
     tmp &= ~(1UL << (pl022->cur_cs));
              ~~~ ^  ~~~~~~~~~~~~~~~
   drivers/spi/spi-pl022.c:453:26: error: no member named 'cur_cs' in 'struct pl022'; did you mean 'cur_msg'?
     tmp |= (1UL << (pl022->cur_cs));
                            ^~~~~~
                            cur_msg
   drivers/spi/spi-pl022.c:379:22: note: 'cur_msg' declared here
    struct spi_message *cur_msg;
                        ^
   drivers/spi/spi-pl022.c:453:15: error: invalid operands to binary expression ('unsigned long' and 'struct spi_message *')
     tmp |= (1UL << (pl022->cur_cs));
             ~~~ ^  ~~~~~~~~~~~~~~~
>> drivers/spi/spi-pl022.c:502:4: error: implicit declaration of function 'pl022_cs_control' [-Werror,-Wimplicit-function-declaration]
      pl022_cs_control(pl022, SSP_CHIP_DESELECT);
      ^
   drivers/spi/spi-pl022.c:843:3: error: implicit declaration of function 'pl022_cs_control' [-Werror,-Wimplicit-function-declaration]
     pl022_cs_control(pl022, SSP_CHIP_DESELECT);
     ^
   drivers/spi/spi-pl022.c:1314:4: error: implicit declaration of function 'pl022_cs_control' [-Werror,-Wimplicit-function-declaration]
      pl022_cs_control(pl022, SSP_CHIP_DESELECT);
      ^
   drivers/spi/spi-pl022.c:1397:4: error: implicit declaration of function 'pl022_cs_control' [-Werror,-Wimplicit-function-declaration]
      pl022_cs_control(pl022, SSP_CHIP_SELECT);
      ^
   drivers/spi/spi-pl022.c:1436:3: error: implicit declaration of function 'pl022_cs_control' [-Werror,-Wimplicit-function-declaration]
     pl022_cs_control(pl022, SSP_CHIP_SELECT);
     ^
   drivers/spi/spi-pl022.c:1510:5: error: implicit declaration of function 'pl022_cs_control' [-Werror,-Wimplicit-function-declaration]
       pl022_cs_control(pl022, SSP_CHIP_SELECT);
       ^
   drivers/spi/spi-pl022.c:1515:5: error: implicit declaration of function 'pl022_cs_control' [-Werror,-Wimplicit-function-declaration]
       pl022_cs_control(pl022, SSP_CHIP_SELECT);
       ^
   drivers/spi/spi-pl022.c:1551:4: error: implicit declaration of function 'pl022_cs_control' [-Werror,-Wimplicit-function-declaration]
      pl022_cs_control(pl022, SSP_CHIP_DESELECT);
      ^
>> drivers/spi/spi-pl022.c:1580:25: error: no member named 'chipselects' in 'struct pl022'
    pl022->cur_cs = pl022->chipselects[msg->spi->chip_select];
                    ~~~~~  ^
   drivers/spi/spi-pl022.c:1580:9: error: no member named 'cur_cs' in 'struct pl022'; did you mean 'cur_msg'?
    pl022->cur_cs = pl022->chipselects[msg->spi->chip_select];
           ^~~~~~
           cur_msg
   drivers/spi/spi-pl022.c:379:22: note: 'cur_msg' declared here
    struct spi_message *cur_msg;
                        ^
>> drivers/spi/spi-pl022.c:1861:4: error: implicit declaration of function 'of_property_read_u32' [-Werror,-Wimplicit-function-declaration]
      of_property_read_u32(np, "pl022,interface",
      ^
>> drivers/spi/spi-pl022.c:1923:7: error: implicit declaration of function 'gpio_is_valid' [-Werror,-Wimplicit-function-declaration]
    if (!gpio_is_valid(pl022->chipselects[spi->chip_select]))
         ^
   drivers/spi/spi-pl022.c:1923:7: note: did you mean 'uuid_is_valid'?
   include/linux/uuid.h:79:46: note: 'uuid_is_valid' declared here
   bool __attribute__((__warn_unused_result__)) uuid_is_valid(const char *uuid);
                                                ^
   drivers/spi/spi-pl022.c:1923:28: error: no member named 'chipselects' in 'struct pl022'
    if (!gpio_is_valid(pl022->chipselects[spi->chip_select]))
                       ~~~~~  ^
   drivers/spi/spi-pl022.c:2086:2: error: implicit declaration of function 'of_property_read_u32' [-Werror,-Wimplicit-function-declaration]
    of_property_read_u32(np, "num-cs", &tmp);
    ^
>> drivers/spi/spi-pl022.c:2090:11: error: implicit declaration of function 'of_property_read_bool' [-Werror,-Wimplicit-function-declaration]
    pd->rt = of_property_read_bool(np, "pl022,rt");
             ^
   drivers/spi/spi-pl022.c:2090:11: note: did you mean 'of_property_read_u32'?
   drivers/spi/spi-pl022.c:1861:4: note: 'of_property_read_u32' declared here
      of_property_read_u32(np, "pl022,interface",
      ^
   fatal error: too many errors emitted, stopping now [-ferror-limit=]
   20 errors generated.

vim +451 drivers/spi/spi-pl022.c

b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  338  
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  339  /**
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  340   * struct pl022 - This is the private SSP driver data structure
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  341   * @adev: AMBA device model hookup
12e8b325f drivers/spi/amba-pl022.c Linus Walleij            2011-02-08  342   * @vendor: vendor data for the IP block
12e8b325f drivers/spi/amba-pl022.c Linus Walleij            2011-02-08  343   * @phybase: the physical memory where the SSP device resides
12e8b325f drivers/spi/amba-pl022.c Linus Walleij            2011-02-08  344   * @virtbase: the virtual memory where the SSP is mapped
12e8b325f drivers/spi/amba-pl022.c Linus Walleij            2011-02-08  345   * @clk: outgoing clock "SPICLK" for the SPI bus
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  346   * @master: SPI framework hookup
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  347   * @master_info: controller-specific data from machine setup
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  348   * @pump_transfers: Tasklet used in Interrupt Transfer mode
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  349   * @cur_msg: Pointer to current spi_message being processed
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  350   * @cur_transfer: Pointer to current spi_transfer
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  351   * @cur_chip: pointer to current clients chip(assigned from controller_state)
8b8d71916 drivers/spi/spi-pl022.c  Virupax Sadashivpetimath 2011-11-10  352   * @next_msg_cs_active: the next message in the queue has been examined
8b8d71916 drivers/spi/spi-pl022.c  Virupax Sadashivpetimath 2011-11-10  353   *  and it was found that it uses the same chip select as the previous
8b8d71916 drivers/spi/spi-pl022.c  Virupax Sadashivpetimath 2011-11-10  354   *  message, so we left it active after the previous transfer, and it's
8b8d71916 drivers/spi/spi-pl022.c  Virupax Sadashivpetimath 2011-11-10  355   *  active already.
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  356   * @tx: current position in TX buffer to be read
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  357   * @tx_end: end position in TX buffer to be read
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  358   * @rx: current position in RX buffer to be written
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  359   * @rx_end: end position in RX buffer to be written
12e8b325f drivers/spi/amba-pl022.c Linus Walleij            2011-02-08  360   * @read: the type of read currently going on
12e8b325f drivers/spi/amba-pl022.c Linus Walleij            2011-02-08  361   * @write: the type of write currently going on
12e8b325f drivers/spi/amba-pl022.c Linus Walleij            2011-02-08  362   * @exp_fifo_level: expected FIFO level
12e8b325f drivers/spi/amba-pl022.c Linus Walleij            2011-02-08  363   * @dma_rx_channel: optional channel for RX DMA
12e8b325f drivers/spi/amba-pl022.c Linus Walleij            2011-02-08  364   * @dma_tx_channel: optional channel for TX DMA
12e8b325f drivers/spi/amba-pl022.c Linus Walleij            2011-02-08  365   * @sgt_rx: scattertable for the RX transfer
12e8b325f drivers/spi/amba-pl022.c Linus Walleij            2011-02-08  366   * @sgt_tx: scattertable for the TX transfer
12e8b325f drivers/spi/amba-pl022.c Linus Walleij            2011-02-08  367   * @dummypage: a dummy page used for driving data on the bus with DMA
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  368   */
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  369  struct pl022 {
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  370  	struct amba_device		*adev;
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  371  	struct vendor_data		*vendor;
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  372  	resource_size_t			phybase;
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  373  	void __iomem			*virtbase;
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  374  	struct clk			*clk;
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  375  	struct spi_master		*master;
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  376  	struct pl022_ssp_controller	*master_info;
ffbbdd213 drivers/spi/spi-pl022.c  Linus Walleij            2012-02-22  377  	/* Message per-transfer pump */
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  378  	struct tasklet_struct		pump_transfers;
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09 @379  	struct spi_message		*cur_msg;
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  380  	struct spi_transfer		*cur_transfer;
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  381  	struct chip_data		*cur_chip;
8b8d71916 drivers/spi/spi-pl022.c  Virupax Sadashivpetimath 2011-11-10  382  	bool				next_msg_cs_active;
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  383  	void				*tx;
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  384  	void				*tx_end;
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  385  	void				*rx;
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  386  	void				*rx_end;
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  387  	enum ssp_reading		read;
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  388  	enum ssp_writing		write;
fc05475f8 drivers/spi/amba-pl022.c Linus Walleij            2010-01-22  389  	u32				exp_fifo_level;
083be3f05 drivers/spi/spi-pl022.c  Linus Walleij            2011-06-16  390  	enum ssp_rx_level_trig		rx_lev_trig;
083be3f05 drivers/spi/spi-pl022.c  Linus Walleij            2011-06-16  391  	enum ssp_tx_level_trig		tx_lev_trig;
b1b6b9aa6 drivers/spi/amba-pl022.c Linus Walleij            2010-09-29  392  	/* DMA settings */
b1b6b9aa6 drivers/spi/amba-pl022.c Linus Walleij            2010-09-29  393  #ifdef CONFIG_DMA_ENGINE
b1b6b9aa6 drivers/spi/amba-pl022.c Linus Walleij            2010-09-29  394  	struct dma_chan			*dma_rx_channel;
b1b6b9aa6 drivers/spi/amba-pl022.c Linus Walleij            2010-09-29  395  	struct dma_chan			*dma_tx_channel;
b1b6b9aa6 drivers/spi/amba-pl022.c Linus Walleij            2010-09-29  396  	struct sg_table			sgt_rx;
b1b6b9aa6 drivers/spi/amba-pl022.c Linus Walleij            2010-09-29  397  	struct sg_table			sgt_tx;
b1b6b9aa6 drivers/spi/amba-pl022.c Linus Walleij            2010-09-29  398  	char				*dummypage;
ffbbdd213 drivers/spi/spi-pl022.c  Linus Walleij            2012-02-22  399  	bool				dma_running;
b1b6b9aa6 drivers/spi/amba-pl022.c Linus Walleij            2010-09-29  400  #endif
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  401  };
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  402  
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  403  /**
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  404   * struct chip_data - To maintain runtime state of SSP for each client chip
556f4aeb7 drivers/spi/amba-pl022.c Linus Walleij            2010-05-05  405   * @cr0: Value of control register CR0 of SSP - on later ST variants this
556f4aeb7 drivers/spi/amba-pl022.c Linus Walleij            2010-05-05  406   *       register is 32 bits wide rather than just 16
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  407   * @cr1: Value of control register CR1 of SSP
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  408   * @dmacr: Value of DMA control Register of SSP
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  409   * @cpsr: Value of Clock prescale register
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  410   * @n_bytes: how many bytes(power of 2) reqd for a given data width of client
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  411   * @enable_dma: Whether to enable DMA or not
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  412   * @read: function ptr to be used to read when doing xfer for this chip
12e8b325f drivers/spi/amba-pl022.c Linus Walleij            2011-02-08  413   * @write: function ptr to be used to write when doing xfer for this chip
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  414   * @xfer_type: polling/interrupt/DMA
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  415   *
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  416   * Runtime state of the SSP controller, maintained per chip,
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  417   * This would be set according to the current message that would be served
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  418   */
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  419  struct chip_data {
556f4aeb7 drivers/spi/amba-pl022.c Linus Walleij            2010-05-05  420  	u32 cr0;
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  421  	u16 cr1;
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  422  	u16 dmacr;
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  423  	u16 cpsr;
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  424  	u8 n_bytes;
b1b6b9aa6 drivers/spi/amba-pl022.c Linus Walleij            2010-09-29  425  	bool enable_dma;
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  426  	enum ssp_reading read;
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  427  	enum ssp_writing write;
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  428  	int xfer_type;
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  429  };
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  430  
d52781e8b drivers/spi/spi-pl022.c  Linus Walleij            2019-06-25  431  static void pl022_set_cs(struct spi_device *spi, bool enable)
db4fa45ed drivers/spi/spi-pl022.c  Anders Berg              2014-09-17  432  {
d52781e8b drivers/spi/spi-pl022.c  Linus Walleij            2019-06-25  433  	struct pl022 *pl022 = spi_controller_get_devdata(spi->controller);
db4fa45ed drivers/spi/spi-pl022.c  Anders Berg              2014-09-17  434  	u32 tmp;
db4fa45ed drivers/spi/spi-pl022.c  Anders Berg              2014-09-17  435  
d52781e8b drivers/spi/spi-pl022.c  Linus Walleij            2019-06-25  436  	/*
d52781e8b drivers/spi/spi-pl022.c  Linus Walleij            2019-06-25  437  	 * This callback will ONLY be called of no GPIO descriptors were found
d52781e8b drivers/spi/spi-pl022.c  Linus Walleij            2019-06-25  438  	 * for the device, so we know we are dealing exclusively with variants
d52781e8b drivers/spi/spi-pl022.c  Linus Walleij            2019-06-25  439  	 * that have internal CS control here, but just to be sure: extra check
d52781e8b drivers/spi/spi-pl022.c  Linus Walleij            2019-06-25  440  	 * for now.
d52781e8b drivers/spi/spi-pl022.c  Linus Walleij            2019-06-25  441  	 */
d52781e8b drivers/spi/spi-pl022.c  Linus Walleij            2019-06-25  442  	if (!pl022->vendor->internal_cs_ctrl) {
d52781e8b drivers/spi/spi-pl022.c  Linus Walleij            2019-06-25  443  		dev_err(&spi->dev,
d52781e8b drivers/spi/spi-pl022.c  Linus Walleij            2019-06-25  444  			"called internal CS control on unsupported device\n");
d52781e8b drivers/spi/spi-pl022.c  Linus Walleij            2019-06-25  445  		return;
d52781e8b drivers/spi/spi-pl022.c  Linus Walleij            2019-06-25  446  	}
d52781e8b drivers/spi/spi-pl022.c  Linus Walleij            2019-06-25  447  
d52781e8b drivers/spi/spi-pl022.c  Linus Walleij            2019-06-25  448  	/* We draw a line low here to imply we enable it */
db4fa45ed drivers/spi/spi-pl022.c  Anders Berg              2014-09-17  449  	tmp = readw(SSP_CSR(pl022->virtbase));
d52781e8b drivers/spi/spi-pl022.c  Linus Walleij            2019-06-25  450  	if (enable)
db4fa45ed drivers/spi/spi-pl022.c  Anders Berg              2014-09-17 @451  		tmp &= ~BIT(pl022->cur_cs);
db4fa45ed drivers/spi/spi-pl022.c  Anders Berg              2014-09-17  452  	else
db4fa45ed drivers/spi/spi-pl022.c  Anders Berg              2014-09-17  453  		tmp |= BIT(pl022->cur_cs);
db4fa45ed drivers/spi/spi-pl022.c  Anders Berg              2014-09-17  454  	writew(tmp, SSP_CSR(pl022->virtbase));
db4fa45ed drivers/spi/spi-pl022.c  Anders Berg              2014-09-17  455  }
db4fa45ed drivers/spi/spi-pl022.c  Anders Berg              2014-09-17  456  
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  457  /**
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  458   * giveback - current spi_message is over, schedule next message and call
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  459   * callback of this message. Assumes that caller already
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  460   * set message->status; dma and pio irqs are blocked
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  461   * @pl022: SSP driver private data structure
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  462   */
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  463  static void giveback(struct pl022 *pl022)
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  464  {
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  465  	struct spi_transfer *last_transfer;
8b8d71916 drivers/spi/spi-pl022.c  Virupax Sadashivpetimath 2011-11-10  466  	pl022->next_msg_cs_active = false;
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  467  
23e2c2aa4 drivers/spi/spi-pl022.c  Axel Lin                 2014-02-12  468  	last_transfer = list_last_entry(&pl022->cur_msg->transfers,
23e2c2aa4 drivers/spi/spi-pl022.c  Axel Lin                 2014-02-12  469  					struct spi_transfer, transfer_list);
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  470  
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  471  	/* Delay if requested before any change in chip select */
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  472  	if (last_transfer->delay_usecs)
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  473  		/*
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  474  		 * FIXME: This runs in interrupt context.
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  475  		 * Is this really smart?
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  476  		 */
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  477  		udelay(last_transfer->delay_usecs);
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  478  
8b8d71916 drivers/spi/spi-pl022.c  Virupax Sadashivpetimath 2011-11-10  479  	if (!last_transfer->cs_change) {
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  480  		struct spi_message *next_msg;
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  481  
8b8d71916 drivers/spi/spi-pl022.c  Virupax Sadashivpetimath 2011-11-10  482  		/*
8b8d71916 drivers/spi/spi-pl022.c  Virupax Sadashivpetimath 2011-11-10  483  		 * cs_change was not set. We can keep the chip select
8b8d71916 drivers/spi/spi-pl022.c  Virupax Sadashivpetimath 2011-11-10  484  		 * enabled if there is message in the queue and it is
8b8d71916 drivers/spi/spi-pl022.c  Virupax Sadashivpetimath 2011-11-10  485  		 * for the same spi device.
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  486  		 *
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  487  		 * We cannot postpone this until pump_messages, because
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  488  		 * after calling msg->complete (below) the driver that
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  489  		 * sent the current message could be unloaded, which
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  490  		 * could invalidate the cs_control() callback...
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  491  		 */
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  492  		/* get a pointer to the next message, if any */
ffbbdd213 drivers/spi/spi-pl022.c  Linus Walleij            2012-02-22  493  		next_msg = spi_get_next_queued_message(pl022->master);
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  494  
8b8d71916 drivers/spi/spi-pl022.c  Virupax Sadashivpetimath 2011-11-10  495  		/*
8b8d71916 drivers/spi/spi-pl022.c  Virupax Sadashivpetimath 2011-11-10  496  		 * see if the next and current messages point
8b8d71916 drivers/spi/spi-pl022.c  Virupax Sadashivpetimath 2011-11-10  497  		 * to the same spi device.
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  498  		 */
8b8d71916 drivers/spi/spi-pl022.c  Virupax Sadashivpetimath 2011-11-10  499  		if (next_msg && next_msg->spi != pl022->cur_msg->spi)
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  500  			next_msg = NULL;
8b8d71916 drivers/spi/spi-pl022.c  Virupax Sadashivpetimath 2011-11-10  501  		if (!next_msg || pl022->cur_msg->state == STATE_ERROR)
f6f46de10 drivers/spi/spi-pl022.c  Roland Stigge            2012-08-22 @502  			pl022_cs_control(pl022, SSP_CHIP_DESELECT);
8b8d71916 drivers/spi/spi-pl022.c  Virupax Sadashivpetimath 2011-11-10  503  		else
8b8d71916 drivers/spi/spi-pl022.c  Virupax Sadashivpetimath 2011-11-10  504  			pl022->next_msg_cs_active = true;
ffbbdd213 drivers/spi/spi-pl022.c  Linus Walleij            2012-02-22  505  
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  506  	}
8b8d71916 drivers/spi/spi-pl022.c  Virupax Sadashivpetimath 2011-11-10  507  
8b8d71916 drivers/spi/spi-pl022.c  Virupax Sadashivpetimath 2011-11-10  508  	pl022->cur_msg = NULL;
8b8d71916 drivers/spi/spi-pl022.c  Virupax Sadashivpetimath 2011-11-10  509  	pl022->cur_transfer = NULL;
8b8d71916 drivers/spi/spi-pl022.c  Virupax Sadashivpetimath 2011-11-10  510  	pl022->cur_chip = NULL;
fd316941c drivers/spi/spi-pl022.c  Virupax Sadashivpetimath 2012-06-12  511  
fd316941c drivers/spi/spi-pl022.c  Virupax Sadashivpetimath 2012-06-12  512  	/* disable the SPI/SSP operation */
fd316941c drivers/spi/spi-pl022.c  Virupax Sadashivpetimath 2012-06-12  513  	writew((readw(SSP_CR1(pl022->virtbase)) &
fd316941c drivers/spi/spi-pl022.c  Virupax Sadashivpetimath 2012-06-12  514  		(~SSP_CR1_MASK_SSE)), SSP_CR1(pl022->virtbase));
fd316941c drivers/spi/spi-pl022.c  Virupax Sadashivpetimath 2012-06-12  515  
cd6fa8d2c drivers/spi/spi-pl022.c  Alexander Sverdlin       2015-02-27  516  	spi_finalize_current_message(pl022->master);
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  517  }
b43d65f7e drivers/spi/amba-pl022.c Linus Walleij            2009-06-09  518  

:::::: The code at line 451 was first introduced by commit
:::::: db4fa45ed3182d8206af241811dfc99369ffa849 spi: pl022: Add support for chip select extension

:::::: TO: Anders Berg <anders.berg@xxxxxxxxxxxxx>
:::::: CC: Mark Brown <broonie@xxxxxxxxxx>

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

Attachment: .config.gz
Description: application/gzip


[Index of Archives]     [Linux SPI]     [Linux Kernel]     [Linux ARM (vger)]     [Linux ARM MSM]     [Linux Omap]     [Linux Arm]     [Linux Tegra]     [Fedora ARM]     [Linux for Samsung SOC]     [eCos]     [Linux Fastboot]     [Gcc Help]     [Git]     [DCCP]     [IETF Announce]     [Security]     [Linux MIPS]     [Yosemite Campsites]

  Powered by Linux