162306a36Sopenharmony_ci/* SPDX-License-Identifier: GPL-2.0-only */ 262306a36Sopenharmony_ci/* 362306a36Sopenharmony_ci * vivid-radio-common.h - common radio rx/tx support functions. 462306a36Sopenharmony_ci * 562306a36Sopenharmony_ci * Copyright 2014 Cisco Systems, Inc. and/or its affiliates. All rights reserved. 662306a36Sopenharmony_ci */ 762306a36Sopenharmony_ci 862306a36Sopenharmony_ci#ifndef _VIVID_RADIO_COMMON_H_ 962306a36Sopenharmony_ci#define _VIVID_RADIO_COMMON_H_ 1062306a36Sopenharmony_ci 1162306a36Sopenharmony_ci/* The supported radio frequency ranges in kHz */ 1262306a36Sopenharmony_ci#define FM_FREQ_RANGE_LOW (64000U * 16U) 1362306a36Sopenharmony_ci#define FM_FREQ_RANGE_HIGH (108000U * 16U) 1462306a36Sopenharmony_ci#define AM_FREQ_RANGE_LOW (520U * 16U) 1562306a36Sopenharmony_ci#define AM_FREQ_RANGE_HIGH (1710U * 16U) 1662306a36Sopenharmony_ci#define SW_FREQ_RANGE_LOW (2300U * 16U) 1762306a36Sopenharmony_ci#define SW_FREQ_RANGE_HIGH (26100U * 16U) 1862306a36Sopenharmony_ci 1962306a36Sopenharmony_cienum { BAND_FM, BAND_AM, BAND_SW, TOT_BANDS }; 2062306a36Sopenharmony_ci 2162306a36Sopenharmony_ciextern const struct v4l2_frequency_band vivid_radio_bands[TOT_BANDS]; 2262306a36Sopenharmony_ci 2362306a36Sopenharmony_ciint vivid_radio_g_frequency(struct file *file, const unsigned *freq, struct v4l2_frequency *vf); 2462306a36Sopenharmony_ciint vivid_radio_s_frequency(struct file *file, unsigned *freq, const struct v4l2_frequency *vf); 2562306a36Sopenharmony_ci 2662306a36Sopenharmony_civoid vivid_radio_rds_init(struct vivid_dev *dev); 2762306a36Sopenharmony_ci 2862306a36Sopenharmony_ci#endif 29