Code Review
/
kvmfornfv.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
review
|
tree
raw
|
inline
| side by side
These changes are the raw update to linux-4.4.6-rt14. Kernel sources
[kvmfornfv.git]
/
kernel
/
sound
/
drivers
/
pcsp
/
pcsp.c
diff --git
a/kernel/sound/drivers/pcsp/pcsp.c
b/kernel/sound/drivers/pcsp/pcsp.c
index
d9647bd
..
27e25bb
100644
(file)
--- a/
kernel/sound/drivers/pcsp/pcsp.c
+++ b/
kernel/sound/drivers/pcsp/pcsp.c
@@
-42,16
+42,13
@@
struct snd_pcsp pcsp_chip;
static int snd_pcsp_create(struct snd_card *card)
{
static struct snd_device_ops ops = { };
static int snd_pcsp_create(struct snd_card *card)
{
static struct snd_device_ops ops = { };
- struct timespec tp;
- int err;
- int div, min_div, order;
-
- hrtimer_get_res(CLOCK_MONOTONIC, &tp);
+ unsigned int resolution = hrtimer_resolution;
+ int err, div, min_div, order;
if (!nopcm) {
if (!nopcm) {
- if (
tp.tv_sec || tp.tv_nsec
> PCSP_MAX_PERIOD_NS) {
+ if (
resolution
> PCSP_MAX_PERIOD_NS) {
printk(KERN_ERR "PCSP: Timer resolution is not sufficient "
printk(KERN_ERR "PCSP: Timer resolution is not sufficient "
- "(%
linS)\n", tp.tv_nsec
);
+ "(%
unS)\n", resolution
);
printk(KERN_ERR "PCSP: Make sure you have HPET and ACPI "
"enabled.\n");
printk(KERN_ERR "PCSP: Turned into nopcm mode.\n");
printk(KERN_ERR "PCSP: Make sure you have HPET and ACPI "
"enabled.\n");
printk(KERN_ERR "PCSP: Turned into nopcm mode.\n");
@@
-59,13
+56,13
@@
static int snd_pcsp_create(struct snd_card *card)
}
}
}
}
- if (loops_per_jiffy >= PCSP_MIN_LPJ &&
tp.tv_nsec
<= PCSP_MIN_PERIOD_NS)
+ if (loops_per_jiffy >= PCSP_MIN_LPJ &&
resolution
<= PCSP_MIN_PERIOD_NS)
min_div = MIN_DIV;
else
min_div = MAX_DIV;
#if PCSP_DEBUG
min_div = MIN_DIV;
else
min_div = MAX_DIV;
#if PCSP_DEBUG
- printk(KERN_DEBUG "PCSP: lpj=%li, min_div=%i, res=%
li
\n",
- loops_per_jiffy, min_div,
tp.tv_nsec
);
+ printk(KERN_DEBUG "PCSP: lpj=%li, min_div=%i, res=%
u
\n",
+ loops_per_jiffy, min_div,
resolution
);
#endif
div = MAX_DIV / min_div;
#endif
div = MAX_DIV / min_div;