blob: b69d8366a667548db66c49c245155a93838b845f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
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
|