linux/drivers/counter/ftm-quaddec.c

// SPDX-License-Identifier: GPL-2.0
/*
 * Flex Timer Module Quadrature decoder
 *
 * This module implements a driver for decoding the FTM quadrature
 * of ex. a LS1021A
 */

#include <linux/fsl/ftm.h>
#include <linux/module.h>
#include <linux/platform_device.h>
#include <linux/of.h>
#include <linux/io.h>
#include <linux/mutex.h>
#include <linux/counter.h>
#include <linux/bitfield.h>
#include <linux/types.h>

#define FTM_FIELD_UPDATE(ftm, offset, mask, val)

struct ftm_quaddec {};

static void ftm_read(struct ftm_quaddec *ftm, uint32_t offset, uint32_t *data)
{}

static void ftm_write(struct ftm_quaddec *ftm, uint32_t offset, uint32_t data)
{}

/* Hold mutex before modifying write protection state */
static void ftm_clear_write_protection(struct ftm_quaddec *ftm)
{}

static void ftm_set_write_protection(struct ftm_quaddec *ftm)
{}

static void ftm_reset_counter(struct ftm_quaddec *ftm)
{}

static void ftm_quaddec_init(struct ftm_quaddec *ftm)
{}

static void ftm_quaddec_disable(void *ftm)
{}

static int ftm_quaddec_get_prescaler(struct counter_device *counter,
				     struct counter_count *count, u32 *cnt_mode)
{}

static int ftm_quaddec_set_prescaler(struct counter_device *counter,
				     struct counter_count *count, u32 cnt_mode)
{}

static const char * const ftm_quaddec_prescaler[] =;

static const enum counter_synapse_action ftm_quaddec_synapse_actions[] =;

static const enum counter_function ftm_quaddec_count_functions[] =;

static int ftm_quaddec_count_read(struct counter_device *counter,
				  struct counter_count *count,
				  u64 *val)
{}

static int ftm_quaddec_count_write(struct counter_device *counter,
				   struct counter_count *count,
				   const u64 val)
{}

static int ftm_quaddec_count_function_read(struct counter_device *counter,
					   struct counter_count *count,
					   enum counter_function *function)
{}

static int ftm_quaddec_action_read(struct counter_device *counter,
				   struct counter_count *count,
				   struct counter_synapse *synapse,
				   enum counter_synapse_action *action)
{}

static const struct counter_ops ftm_quaddec_cnt_ops =;

static struct counter_signal ftm_quaddec_signals[] =;

static struct counter_synapse ftm_quaddec_count_synapses[] =;

static DEFINE_COUNTER_ENUM(ftm_quaddec_prescaler_enum, ftm_quaddec_prescaler);

static struct counter_comp ftm_quaddec_count_ext[] =;

static struct counter_count ftm_quaddec_counts =;

static int ftm_quaddec_probe(struct platform_device *pdev)
{}

static const struct of_device_id ftm_quaddec_match[] =;

static struct platform_driver ftm_quaddec_driver =;

module_platform_driver();

MODULE_DESCRIPTION();
MODULE_LICENSE();
MODULE_AUTHOR();
MODULE_AUTHOR();
MODULE_IMPORT_NS();