diff options
author | Heiner Kallweit <hkallweit1@gmail.com> | 2020-03-01 01:29:07 +0300 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2020-03-05 01:21:00 +0300 |
commit | ec46bf925a7f5c824dbf5278995ff8997c00a538 (patch) | |
tree | ef3024987c045ae8c12f845d0ac4f775a5d37f5e /sound/pci | |
parent | 75e1fd42e6e1de3b2709c77897156d9a695d6a73 (diff) | |
download | linux-ec46bf925a7f5c824dbf5278995ff8997c00a538.tar.xz |
sound: bt87x: use pci_status_get_and_clear_errors
Use new helper pci_status_get_and_clear_errors() to simplify the code.
Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'sound/pci')
-rw-r--r-- | sound/pci/bt87x.c | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/sound/pci/bt87x.c b/sound/pci/bt87x.c index 8c48864c844a..6567504665b9 100644 --- a/sound/pci/bt87x.c +++ b/sound/pci/bt87x.c @@ -271,13 +271,8 @@ static void snd_bt87x_free_risc(struct snd_bt87x *chip) static void snd_bt87x_pci_error(struct snd_bt87x *chip, unsigned int status) { - u16 pci_status; + int pci_status = pci_status_get_and_clear_errors(chip->pci); - pci_read_config_word(chip->pci, PCI_STATUS, &pci_status); - pci_status &= PCI_STATUS_PARITY | PCI_STATUS_SIG_TARGET_ABORT | - PCI_STATUS_REC_TARGET_ABORT | PCI_STATUS_REC_MASTER_ABORT | - PCI_STATUS_SIG_SYSTEM_ERROR | PCI_STATUS_DETECTED_PARITY; - pci_write_config_word(chip->pci, PCI_STATUS, pci_status); if (pci_status != PCI_STATUS_DETECTED_PARITY) dev_err(chip->card->dev, "Aieee - PCI error! status %#08x, PCI status %#04x\n", |