Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
linux
Commits
fd1126ca
Commit
fd1126ca
authored
Jul 21, 2011
by
Mauro Carvalho Chehab
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[media] mt2063: Use linux default max function
Signed-off-by:
Mauro Carvalho Chehab
<
mchehab@redhat.com
>
parent
8c64f932
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
31 deletions
+3
-31
drivers/media/common/tuners/mt2063.c
drivers/media/common/tuners/mt2063.c
+3
-31
No files found.
drivers/media/common/tuners/mt2063.c
View file @
fd1126ca
...
...
@@ -951,34 +951,6 @@ static u32 MT2063_gcd(u32 u, u32 v)
return
u
;
}
/****************************************************************************
**
** Name: umax
**
** Description: Implements a simple maximum function for unsigned numbers.
** Implemented as a function rather than a macro to avoid
** multiple evaluation of the calling parameters.
**
** Parameters: a, b - Values to be compared
**
** Global: None
**
** Returns: larger of the input values.
**
** Dependencies: None.
**
** Revision History:
**
** SCR Date Author Description
** -------------------------------------------------------------------------
** N/A 06-02-2004 JWS Original
**
****************************************************************************/
static
u32
MT2063_umax
(
u32
a
,
u32
b
)
{
return
(
a
>=
b
)
?
a
:
b
;
}
/****************************************************************************
**
** Name: IsSpurInBand
...
...
@@ -1037,11 +1009,11 @@ static u32 IsSpurInBand(struct MT2063_AvoidSpursData_t *pAS_Info,
** gcd-based scale factor or f_Scale.
*/
lo_gcd
=
MT2063_gcd
(
f_LO1
,
f_LO2
);
gd_Scale
=
MT2063_u
max
((
u32
)
MT2063_gcd
(
lo_gcd
,
d
),
f_Scale
);
gd_Scale
=
max
((
u32
)
MT2063_gcd
(
lo_gcd
,
d
),
f_Scale
);
hgds
=
gd_Scale
/
2
;
gc_Scale
=
MT2063_u
max
((
u32
)
MT2063_gcd
(
lo_gcd
,
c
),
f_Scale
);
gc_Scale
=
max
((
u32
)
MT2063_gcd
(
lo_gcd
,
c
),
f_Scale
);
hgcs
=
gc_Scale
/
2
;
gf_Scale
=
MT2063_u
max
((
u32
)
MT2063_gcd
(
lo_gcd
,
f
),
f_Scale
);
gf_Scale
=
max
((
u32
)
MT2063_gcd
(
lo_gcd
,
f
),
f_Scale
);
hgfs
=
gf_Scale
/
2
;
n0
=
DIV_ROUND_UP
(
f_LO2
-
d
,
f_LO1
-
f_LO2
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment