summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorcodeworkx <codeworkx@cyanogenmod.org>2012-12-13 17:23:45 +0100
committercodeworkx <codeworkx@cyanogenmod.org>2012-12-13 17:23:45 +0100
commit84f8d1d325333f9d904ec3311763d4169a8145e8 (patch)
tree2516bc7dfa1f574c921886d5a8db57c01720e374
parentd052b701d224b3b6cbd0a2e4a3a7a17d98c2fd06 (diff)
downloadhardware_samsung-84f8d1d325333f9d904ec3311763d4169a8145e8.zip
hardware_samsung-84f8d1d325333f9d904ec3311763d4169a8145e8.tar.gz
hardware_samsung-84f8d1d325333f9d904ec3311763d4169a8145e8.tar.bz2
macloader: add new murata value
Change-Id: I1bc1aa88ec58f406fcf46a7c118ef577d6b0fb78
-rw-r--r--macloader/macloader.cpp16
1 files changed, 9 insertions, 7 deletions
diff --git a/macloader/macloader.cpp b/macloader/macloader.cpp
index c382912..a8a2871 100644
--- a/macloader/macloader.cpp
+++ b/macloader/macloader.cpp
@@ -40,6 +40,7 @@ enum Type {
* murata:
* 00:37:6d
* 88:30:8a
+ * 60:21:C0
*
* semcosh:
* 5c:0a:5b
@@ -57,7 +58,7 @@ int main() {
/* open mac addr file */
file = fopen(MACADDR_PATH, "r");
- if(file == 0) {
+ if (file == 0) {
fprintf(stderr, "open(%s) failed\n", MACADDR_PATH);
ALOGE("Can't open %s\n", MACADDR_PATH);
return -1;
@@ -65,21 +66,22 @@ int main() {
/* get and compare mac addr */
str = fgets(mac_addr_half, 9, file);
- if(str == 0) {
+ if (str == 0) {
fprintf(stderr, "fgets() from file %s failed\n", MACADDR_PATH);
ALOGE("Can't read from %s\n", MACADDR_PATH);
return -1;
}
/* murata */
- if(strncasecmp(mac_addr_half, "00:37:6d", 9) == 0 ||
+ if (strncasecmp(mac_addr_half, "00:37:6d", 9) == 0 ||
strncasecmp(mac_addr_half, "88:30:8a", 9) == 0 ||
- strncasecmp(mac_addr_half, "20:02:af", 9) == 0) {
+ strncasecmp(mac_addr_half, "20:02:af", 9) == 0 ||
+ strncasecmp(mac_addr_half, "60:21:C0", 9) == 0) {
type = MURATA;
}
/* semcosh */
- if(strncasecmp(mac_addr_half, "5c:0a:5b", 9) == 0) {
+ if (strncasecmp(mac_addr_half, "5c:0a:5b", 9) == 0) {
type = SEMCOSH;
}
@@ -113,7 +115,7 @@ int main() {
break;
}
- if(ret != 0) {
+ if (ret != 0) {
fprintf(stderr, "fputs() to file %s failed\n", CID_PATH);
ALOGE("Can't write to %s\n", CID_PATH);
return -1;
@@ -132,7 +134,7 @@ int main() {
system(chown_cmd);
system(chgrp_cmd);
- if(ret != 0) {
+ if (ret != 0) {
fprintf(stderr, "chmod() on file %s failed\n", CID_PATH);
ALOGE("Can't set permissions on %s\n", CID_PATH);
return ret;