mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-10-02 15:18:19 +00:00
Merge remote-tracking branches 'spi/fix/spidev' and 'spi/fix/xtfpga' into spi-linus
This commit is contained in:
commit
711e020cae
2 changed files with 4 additions and 3 deletions
|
@ -34,13 +34,13 @@ struct xtfpga_spi {
|
||||||
static inline void xtfpga_spi_write32(const struct xtfpga_spi *spi,
|
static inline void xtfpga_spi_write32(const struct xtfpga_spi *spi,
|
||||||
unsigned addr, u32 val)
|
unsigned addr, u32 val)
|
||||||
{
|
{
|
||||||
iowrite32(val, spi->regs + addr);
|
__raw_writel(val, spi->regs + addr);
|
||||||
}
|
}
|
||||||
|
|
||||||
static inline unsigned int xtfpga_spi_read32(const struct xtfpga_spi *spi,
|
static inline unsigned int xtfpga_spi_read32(const struct xtfpga_spi *spi,
|
||||||
unsigned addr)
|
unsigned addr)
|
||||||
{
|
{
|
||||||
return ioread32(spi->regs + addr);
|
return __raw_readl(spi->regs + addr);
|
||||||
}
|
}
|
||||||
|
|
||||||
static inline void xtfpga_spi_wait_busy(struct xtfpga_spi *xspi)
|
static inline void xtfpga_spi_wait_busy(struct xtfpga_spi *xspi)
|
||||||
|
|
|
@ -651,7 +651,8 @@ static int spidev_release(struct inode *inode, struct file *filp)
|
||||||
kfree(spidev->rx_buffer);
|
kfree(spidev->rx_buffer);
|
||||||
spidev->rx_buffer = NULL;
|
spidev->rx_buffer = NULL;
|
||||||
|
|
||||||
spidev->speed_hz = spidev->spi->max_speed_hz;
|
if (spidev->spi)
|
||||||
|
spidev->speed_hz = spidev->spi->max_speed_hz;
|
||||||
|
|
||||||
/* ... after we unbound from the underlying device? */
|
/* ... after we unbound from the underlying device? */
|
||||||
spin_lock_irq(&spidev->spi_lock);
|
spin_lock_irq(&spidev->spi_lock);
|
||||||
|
|
Loading…
Reference in a new issue