diff options
author | Christian Pointner <equinox@helsinki.at> | 2024-05-10 18:56:00 (GMT) |
---|---|---|
committer | Christian Pointner <equinox@helsinki.at> | 2024-05-10 18:56:00 (GMT) |
commit | af6bfbbd2496b1f5aa02b94caff4e6f988fa32c9 (patch) | |
tree | 45bebb68a0bf3bfc2fff1646f6fa0f4b976fba57 /snd-alpx-dkms/snd-alpx/alpx_led.h | |
parent | 7035064ca063fdf15669ceb790ecef1e5ed054b0 (diff) |
rename package to snd-alpx-dkms
Diffstat (limited to 'snd-alpx-dkms/snd-alpx/alpx_led.h')
-rw-r--r-- | snd-alpx-dkms/snd-alpx/alpx_led.h | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/snd-alpx-dkms/snd-alpx/alpx_led.h b/snd-alpx-dkms/snd-alpx/alpx_led.h new file mode 100644 index 0000000..b69d836 --- /dev/null +++ b/snd-alpx-dkms/snd-alpx/alpx_led.h @@ -0,0 +1,23 @@ +// SPDX-License-Identifier: GPL-2.0-or-later +/* +* Support for Digigram AlpX PCI-e boards +* +* Copyright (c) 2024 Digigram Digital (info@digigram.com) +*/ + +#ifndef _ALPX_LEDS_H +#define _ALPX_LEDS_H + +#include "alpx.h" + +#include <linux/io.h> + +static inline void alpmadi_set_led_state(struct alpx_device *alpx_dev, bool blink) +{ + writel(blink ? 1 : 0, ALPX_REG(alpx_dev, ALPMADI, CONTROL, BLINK_LED)); + + dev_dbg( alpx_dev->dev,"%s(): LED %s, val:0x%08x/\n", __func__, + blink ? "On":"Off",readl(ALPX_REG(alpx_dev, ALPMADI, CONTROL, BLINK_LED))); +} + +#endif |