svn commit: r230602 - head/sys/dev/sound/pci
Pedro F. Giffuni
pfg at FreeBSD.org
Thu Jan 26 21:43:12 UTC 2012
Author: pfg
Date: Thu Jan 26 21:43:11 2012
New Revision: 230602
URL: http://svn.freebsd.org/changeset/base/230602
Log:
Minor cleanups to the csa snd driver.
Remove unneeded temporary variable (data) to better match the OSS code.
Remove some unused constants and type definitions.
Tested by: joel
Approved by: jhb (mentor)
MFC after: 3 weeks
Modified:
head/sys/dev/sound/pci/csa.c
head/sys/dev/sound/pci/csareg.h
Modified: head/sys/dev/sound/pci/csa.c
==============================================================================
--- head/sys/dev/sound/pci/csa.c Thu Jan 26 20:40:22 2012 (r230601)
+++ head/sys/dev/sound/pci/csa.c Thu Jan 26 21:43:11 2012 (r230602)
@@ -861,7 +861,7 @@ static int
csa_downloadimage(csa_res *resp)
{
int i;
- u_int32_t tmp, src, dst, count, data;
+ u_int32_t tmp, src, dst, count;
for (i = 0; i < CLEAR__COUNT; i++) {
dst = ClrStat[i].BA1__DestByteOffset;
@@ -875,8 +875,7 @@ csa_downloadimage(csa_res *resp)
dst = FillStat[i].Offset;
count = FillStat[i].Size;
for (tmp = 0; tmp < count; tmp += 4) {
- data = FillStat[i].pFill[src];
- csa_writemem(resp, dst + tmp, data);
+ csa_writemem(resp, dst + tmp, FillStat[i].pFill[src]);
src++;
}
}
Modified: head/sys/dev/sound/pci/csareg.h
==============================================================================
--- head/sys/dev/sound/pci/csareg.h Thu Jan 26 20:40:22 2012 (r230601)
+++ head/sys/dev/sound/pci/csareg.h Thu Jan 26 21:43:11 2012 (r230602)
@@ -1949,24 +1949,4 @@
#define CS_AC97_POWER_CONTROL_MIXVON_ON 0x0004
#define CS_AC97_POWER_CONTROL_MIXVOFF_ON 0x0008
-/* The following struct holds the initialization array. */
-
-/*
- * this is 3*1024 for parameter, 3.5*1024 for sample and 2*3.5*1024 for code since
- * each instruction is 40 bits and takes two dwords
- */
-#define INKY_BA1_DWORD_SIZE (13 * 1024 + 512)
-#define INKY_MEMORY_COUNT 3
-
-struct BA1struct
-{
- struct
- {
- u_long ulDestByteOffset,
- ulSourceByteSize;
- } MemoryStat[INKY_MEMORY_COUNT];
-
- u_long BA1Array[INKY_BA1_DWORD_SIZE];
-};
-
#endif /* _CSA_REG_H */
More information about the svn-src-all
mailing list