Loading drivers/misc/qcom/qdsp6v2/aac_in.c +10 −1 Original line number Diff line number Diff line /* * Copyright (c) 2010-2016, The Linux Foundation. All rights reserved. * Copyright (c) 2010-2017, The Linux Foundation. All rights reserved. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 and Loading Loading @@ -34,6 +34,8 @@ #define AAC_FORMAT_ADTS 65535 #define MAX_SAMPLE_RATE_384K 384000 static long aac_in_ioctl_shared(struct file *file, unsigned int cmd, void *arg) { struct q6audio_in *audio = file->private_data; Loading Loading @@ -233,6 +235,13 @@ static long aac_in_ioctl_shared(struct file *file, unsigned int cmd, void *arg) break; } if (cfg->sample_rate > MAX_SAMPLE_RATE_384K) { pr_err("%s: ERROR: invalid sample rate = %u", __func__, cfg->sample_rate); rc = -EINVAL; break; } min_bitrate = ((cfg->sample_rate)*(cfg->channels))/2; /* This calculation should be based on AAC mode. But we cannot * get AAC mode in this setconfig. min_bitrate's logical max Loading Loading
drivers/misc/qcom/qdsp6v2/aac_in.c +10 −1 Original line number Diff line number Diff line /* * Copyright (c) 2010-2016, The Linux Foundation. All rights reserved. * Copyright (c) 2010-2017, The Linux Foundation. All rights reserved. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 and Loading Loading @@ -34,6 +34,8 @@ #define AAC_FORMAT_ADTS 65535 #define MAX_SAMPLE_RATE_384K 384000 static long aac_in_ioctl_shared(struct file *file, unsigned int cmd, void *arg) { struct q6audio_in *audio = file->private_data; Loading Loading @@ -233,6 +235,13 @@ static long aac_in_ioctl_shared(struct file *file, unsigned int cmd, void *arg) break; } if (cfg->sample_rate > MAX_SAMPLE_RATE_384K) { pr_err("%s: ERROR: invalid sample rate = %u", __func__, cfg->sample_rate); rc = -EINVAL; break; } min_bitrate = ((cfg->sample_rate)*(cfg->channels))/2; /* This calculation should be based on AAC mode. But we cannot * get AAC mode in this setconfig. min_bitrate's logical max Loading