1 Index: package/ar7-atm/patches/150-module_params.patch
2 ===================================================================
3 --- package/ar7-atm/patches/150-module_params.patch (revision 0)
4 +++ package/ar7-atm/patches/150-module_params.patch (revision 0)
6 +diff -urN sangam_atm-07.02.01.00/tn7atm.c sangam_atm-07.02.01.00.mod/tn7atm.c
7 +--- sangam_atm-07.02.01.00/tn7atm.c 2007-09-19 04:12:20.000000000 +0200
8 ++++ sangam_atm-07.02.01.00.mod/tn7atm.c 2007-09-20 14:45:19.280250000 +0200
10 + MODULE_LICENSE("GPL");
11 + MODULE_DESCRIPTION ("Tnetd73xx ATM Device Driver");
12 + MODULE_AUTHOR ("Zhicheng Tang");
14 ++int mp_sar_ipacemax = -1;
15 ++module_param_named(ipacemax, mp_sar_ipacemax, int, 0);
16 ++MODULE_PARM_DESC(ipacemax, "Interrupt pacing");
18 ++char *mp_macc = NULL;
19 ++module_param_named(macc, mp_macc, charp, 0);
20 ++MODULE_PARM_DESC(macc, "MAC address");
22 ++int mp_dsp_noboost = -1;
23 ++module_param_named(dsp_noboost, mp_dsp_noboost, int, 0);
24 ++MODULE_PARM_DESC(dsp_noboost, "Suppress DSP frequency boost");
26 ++int mp_dsp_freq = -1;
27 ++module_param_named(dsp_freq, mp_dsp_freq, int, 0);
28 ++MODULE_PARM_DESC(dsp_freq, "Frequency to boost the DSP to");
30 ++char *mp_featctl0 = NULL;
31 ++module_param_named(featctl0, mp_featctl0, charp, 0);
32 ++MODULE_PARM_DESC(featctl0, "DSL feature control 0");
34 ++char *mp_featctl1 = NULL;
35 ++module_param_named(featctl1, mp_featctl1, charp, 0);
36 ++MODULE_PARM_DESC(featctl1, "DSL feature control 1");
38 ++char *mp_phyctl0 = NULL;
39 ++module_param_named(phyctl0, mp_phyctl0, charp, 0);
40 ++MODULE_PARM_DESC(phyctl0, "DSL PHY control 0");
42 ++char *mp_phyctl1 = NULL;
43 ++module_param_named(phyctl1, mp_phyctl1, charp, 0);
44 ++MODULE_PARM_DESC(phyctl1, "DSL PHY control 1");
46 ++int mp_turbodsl = -1;
47 ++module_param_named(turbodsl, mp_turbodsl, int, 0);
48 ++MODULE_PARM_DESC(turbodsl, "Enable TurboDSL");
50 ++int mp_sar_rxbuf = -1;
51 ++module_param_named(sar_rxbuf, mp_sar_rxbuf, int, 0);
52 ++MODULE_PARM_DESC(sar_rxbuf, "SAR RxBuf size");
54 ++int mp_sar_rxmax = -1;
55 ++module_param_named(sar_rxmax, mp_sar_rxmax, int, 0);
56 ++MODULE_PARM_DESC(sar_rxmax, "SAR RxMax size");
58 ++int mp_sar_txbuf = -1;
59 ++module_param_named(sar_txbuf, mp_sar_txbuf, int, 0);
60 ++MODULE_PARM_DESC(sar_txbuf, "SAR TxBuf size");
62 ++int mp_sar_txmax = -1;
63 ++module_param_named(sar_txmax, mp_sar_txmax, int, 0);
64 ++MODULE_PARM_DESC(sar_txmax, "SAR TxMax size");
66 ++char *mp_modulation = NULL;
67 ++module_param_named(modulation, mp_modulation, charp, 0);
68 ++MODULE_PARM_DESC(modulation, "Modulation");
70 ++int mp_fine_gain_control = -1;
71 ++module_param_named(fine_gain_control, mp_fine_gain_control, int, 0);
72 ++MODULE_PARM_DESC(fine_gain_control, "Fine gain control");
74 ++int mp_fine_gain_value = -1;
75 ++module_param_named(fine_gain_value, mp_fine_gain_value, int, 0);
76 ++MODULE_PARM_DESC(fine_gain_value, "Fine gain value");
78 ++int mp_enable_margin_retrain = -1;
79 ++module_param_named(enable_margin_retrain, mp_enable_margin_retrain, int, 0);
80 ++MODULE_PARM_DESC(enable_margin_retrain, "Enable margin retrain");
82 ++int mp_margin_threshold = -1;
83 ++module_param_named(margin_threshold, mp_margin_threshold, int, 0);
84 ++MODULE_PARM_DESC(margin_threshold, "Margin retrain treshold");
86 ++int mp_enable_rate_adapt = -1;
87 ++module_param_named(enable_rate_adapt, mp_enable_rate_adapt, int, 0);
88 ++MODULE_PARM_DESC(enable_rate_adapt, "Enable rate adaption");
90 ++int mp_powercutback = -1;
91 ++module_param_named(powercutback, mp_powercutback, int, 0);
92 ++MODULE_PARM_DESC(powercutback, "Enable / disable powercutback");
94 ++int mp_trellis = -1;
95 ++module_param_named(trellis, mp_trellis, int, 0);
96 ++MODULE_PARM_DESC(trellis, "Enable / disable trellis coding");
98 ++int mp_bitswap = -1;
99 ++module_param_named(bitswap, mp_bitswap, int, 0);
100 ++MODULE_PARM_DESC(bitswap, "Enable / disable bitswap");
102 ++int mp_maximum_bits_per_carrier = -1;
103 ++module_param_named(maximum_bits_per_carrier, mp_maximum_bits_per_carrier, int, 0);
104 ++MODULE_PARM_DESC(maximum_bits_per_carrier, "Maximum bits per carrier");
106 ++int mp_maximum_interleave_depth = -1;
107 ++module_param_named(maximum_interleave_depth, mp_maximum_interleave_depth, int, 0);
108 ++MODULE_PARM_DESC(maximum_interleave_depth, "Maximum interleave depth");
110 ++int mp_pair_selection = -1;
111 ++module_param_named(pair_selection, mp_pair_selection, int, 0);
112 ++MODULE_PARM_DESC(pair_selection, "Pair selection");
114 ++int mp_dgas_polarity = -1;
115 ++module_param_named(dgas_polarity, mp_dgas_polarity, int, 0);
116 ++MODULE_PARM_DESC(dgas_polarity, "DGAS polarity");
118 ++int mp_los_alarm = -1;
119 ++module_param_named(los_alarm, mp_los_alarm, int, 0);
120 ++MODULE_PARM_DESC(los_alarm, "LOS alarm");
122 ++char *mp_eoc_vendor_id = NULL;
123 ++module_param_named(eoc_vendor_id, mp_eoc_vendor_id, charp, 0);
124 ++MODULE_PARM_DESC(eoc_vendor_id, "EOC vendor id");
126 ++int mp_eoc_vendor_revision = -1;
127 ++module_param_named(eoc_vendor_revision, mp_eoc_vendor_revision, int, 0);
128 ++MODULE_PARM_DESC(eoc_vendor_revision, "EOC vendor revision");
130 ++char *mp_eoc_vendor_serialnum = NULL;
131 ++module_param_named(eoc_vendor_serialnum, mp_eoc_vendor_serialnum, charp, 0);
132 ++MODULE_PARM_DESC(eoc_vendor_serialnum, "EOC vendor serial number");
134 ++char *mp_invntry_vernum = NULL;
135 ++module_param_named(invntry_vernum, mp_invntry_vernum, charp, 0);
136 ++MODULE_PARM_DESC(invntry_vernum, "Inventory revision number");
138 ++int mp_dsl_bit_tmode = -1;
139 ++module_param_named(dsl_bit_tmode, mp_dsl_bit_tmode, int, 0);
140 ++MODULE_PARM_DESC(dsl_bit_tmode, "DSL bit training mode");
142 ++int mp_high_precision = -1;
143 ++module_param_named(high_precision, mp_high_precision, int, 0);
144 ++MODULE_PARM_DESC(high_precision, "High precision");
146 ++int mp_autopvc_enable = -1;
147 ++module_param_named(autopvc_enable, mp_autopvc_enable, int, 0);
148 ++MODULE_PARM_DESC(autopvc_enable, "Enable / disable automatic PVC");
150 ++int mp_oam_lb_timeout = -1;
151 ++module_param_named(oam_lb_timeout, mp_oam_lb_timeout, int, 0);
152 ++MODULE_PARM_DESC(oam_lb_timeout, "OAM LB timeout");
159 + ptr = prom_getenv ("sar_ipacemax");
161 ++ if (ptr || mp_sar_ipacemax != -1)
163 +- def_sar_inter_pace = os_atoi (ptr);
164 ++ def_sar_inter_pace = mp_sar_ipacemax == -1 ? os_atoi (ptr) : mp_sar_ipacemax;
166 + /* avalanche_request_pacing (priv->sar_irq, ATM_SAR_INT_PACING_BLOCK_NUM,
167 + def_sar_inter_pace);*/
169 + char esi_addr[ESI_LEN] = { 0x00, 0x00, 0x11, 0x22, 0x33, 0x44 };
170 + char *esiaddr_str = NULL;
172 +- esiaddr_str = prom_getenv ("macc");
173 ++ esiaddr_str = mp_macc ? mp_macc : prom_getenv ("macc");
177 +@@ -1932,15 +2072,15 @@
178 + //UR8_MERGE_END CQ10450*
180 + cp = prom_getenv ("dsp_noboost");
182 ++ if (cp || mp_dsp_noboost != -1)
184 +- dsp_noboost = os_atoi (cp);
185 ++ dsp_noboost = mp_dsp_noboost == -1 ? os_atoi (cp) : mp_dsp_noboost;
188 + cp = (char *) prom_getenv ("dsp_freq");
190 ++ if (cp || mp_dsp_freq != -1)
192 +- dspfreq = os_atoi (cp);
193 ++ dspfreq = mp_dsp_freq == -1 ? os_atoi (cp) : mp_dsp_freq;
194 + if (dspfreq == 250)
197 +@@ -2189,8 +2329,9 @@
198 + // Inter-Op DSL phy Control
199 + // Note the setting of _dsl_Feature_0 and _dsl_Feature_1 must before
200 + // dslhal_api_dslStartup (in tn7dsl_init()).
201 +- if ((ptr = prom_getenv ("DSL_FEATURE_CNTL_0")) != NULL)
202 ++ if ((ptr = prom_getenv ("DSL_FEATURE_CNTL_0")) != NULL || mp_featctl0 != NULL)
204 ++ if (mp_featctl0 != NULL) ptr = mp_featctl0;
205 + if ((ptr[0] == '0') && (ptr[1] == 'x')) // skip 0x before pass to
208 +@@ -2198,8 +2339,9 @@
209 + _dsl_Feature_0_defined = 1;
212 +- if ((ptr = prom_getenv ("DSL_FEATURE_CNTL_1")) != NULL)
213 ++ if ((ptr = prom_getenv ("DSL_FEATURE_CNTL_1")) != NULL || mp_featctl1 != NULL)
215 ++ if (mp_featctl1 != NULL) ptr = mp_featctl1;
216 + if ((ptr[0] == '0') && (ptr[1] == 'x')) // skip 0x before pass to
219 +@@ -2211,8 +2353,9 @@
220 + // DSL phy Feature Control
221 + // Note the setting of _dsl_PhyControl_0 and _dsl_PhyControl_1 must before
222 + // dslhal_api_dslStartup (in tn7dsl_init()).
223 +- if ((ptr = prom_getenv ("DSL_PHY_CNTL_0")) != NULL)
224 ++ if ((ptr = prom_getenv ("DSL_PHY_CNTL_0")) != NULL || mp_phyctl0 != NULL)
226 ++ if (mp_phyctl0 != NULL) ptr = mp_phyctl0;
227 + if ((ptr[0] == '0') && (ptr[1] == 'x')) // skip 0x before pass to
230 +@@ -2220,8 +2363,9 @@
231 + _dsl_PhyControl_0_defined = 1;
234 +- if ((ptr = prom_getenv ("DSL_PHY_CNTL_1")) != NULL)
235 ++ if ((ptr = prom_getenv ("DSL_PHY_CNTL_1")) != NULL || mp_phyctl1 != NULL)
237 ++ if (mp_phyctl1 != NULL) ptr = mp_phyctl1;
238 + if ((ptr[0] == '0') && (ptr[1] == 'x')) // skip 0x before pass to
241 +@@ -2249,9 +2393,9 @@
242 + priv->bTurboDsl = 1;
243 + // read config for turbo dsl
244 + ptr = prom_getenv ("TurboDSL");
246 ++ if (ptr || mp_turbodsl != -1)
248 +- priv->bTurboDsl = os_atoi (ptr);
249 ++ priv->bTurboDsl = mp_turbodsl == -1 ? os_atoi (ptr) : mp_turbodsl;
252 + // @Added to make Rx buffer number & Service max configurable through
253 +@@ -2259,30 +2403,30 @@
254 + priv->sarRxBuf = RX_BUFFER_NUM;
256 + ptr = prom_getenv ("SarRxBuf");
258 ++ if (ptr || mp_sar_rxbuf != -1)
260 +- priv->sarRxBuf = os_atoi (ptr);
261 ++ priv->sarRxBuf = mp_sar_rxbuf == -1 ? os_atoi (ptr) : mp_sar_rxbuf;
263 + priv->sarRxMax = RX_SERVICE_MAX;
265 + ptr = prom_getenv ("SarRxMax");
267 ++ if (ptr || mp_sar_rxmax != -1)
269 +- priv->sarRxMax = os_atoi (ptr);
270 ++ priv->sarRxMax = mp_sar_rxmax == -1 ? os_atoi (ptr) : mp_sar_rxmax;
272 + priv->sarTxBuf = TX_BUFFER_NUM;
274 + ptr = prom_getenv ("SarTxBuf");
276 ++ if (ptr || mp_sar_txbuf != -1)
278 +- priv->sarTxBuf = os_atoi (ptr);
279 ++ priv->sarTxBuf = mp_sar_txbuf == -1 ? os_atoi (ptr) : mp_sar_txbuf;
281 + priv->sarTxMax = TX_SERVICE_MAX;
283 + ptr = prom_getenv ("SarTxMax");
285 ++ if (ptr || mp_sar_txmax != -1)
287 +- priv->sarTxMax = os_atoi (ptr);
288 ++ priv->sarTxMax = mp_sar_txmax == -1 ? os_atoi (ptr) : mp_sar_txmax;
292 +diff -urN sangam_atm-07.02.01.00/tn7dsl.c sangam_atm-07.02.01.00.mod/tn7dsl.c
293 +--- sangam_atm-07.02.01.00/tn7dsl.c 2007-09-19 04:12:20.000000000 +0200
294 ++++ sangam_atm-07.02.01.00.mod/tn7dsl.c 2007-09-20 14:55:46.608375000 +0200
295 +@@ -134,6 +134,27 @@
296 + #define NEW_TRAINING_VAL_T1413 128
297 + #define NEW_TRAINING_VAL_MMODE 255
299 ++extern char *mp_modulation;
300 ++extern int mp_fine_gain_control;
301 ++extern int mp_fine_gain_value;
302 ++extern int mp_enable_margin_retrain;
303 ++extern int mp_margin_threshold;
304 ++extern int mp_enable_rate_adapt;
305 ++extern int mp_powercutback;
306 ++extern int mp_trellis;
307 ++extern int mp_bitswap;
308 ++extern int mp_maximum_bits_per_carrier;
309 ++extern int mp_maximum_interleave_depth;
310 ++extern int mp_pair_selection;
311 ++extern int mp_dgas_polarity;
312 ++extern int mp_los_alarm;
313 ++extern char *mp_eoc_vendor_id;
314 ++extern int mp_eoc_vendor_revision;
315 ++extern char *mp_eoc_vendor_serialnum;
316 ++extern char *mp_invntry_vernum;
317 ++extern int mp_dsl_bit_tmode;
318 ++extern int mp_high_precision;
321 + extern int __guDbgLevel;
322 + extern sar_stat_t sarStat;
323 +@@ -2816,84 +2837,80 @@
326 + ptr = prom_getenv("modulation");
328 ++ if (ptr || mp_modulation != NULL)
330 +- tn7dsl_set_modulation(ptr, FALSE);
331 ++ tn7dsl_set_modulation(mp_modulation == NULL ? ptr : mp_modulation, FALSE);
335 + ptr = prom_getenv("fine_gain_control");
337 ++ if (ptr || mp_fine_gain_control != -1)
339 +- value = os_atoi(ptr);
340 ++ value = mp_fine_gain_control == -1 ? os_atoi(ptr) : mp_fine_gain_control;
341 + tn7dsl_ctrl_fineGain(value);
344 + ptr = prom_getenv("fine_gain_value");
346 +- tn7dsl_set_fineGainValue(os_atoh(ptr));
347 ++ if(ptr || mp_fine_gain_value != -1)
348 ++ tn7dsl_set_fineGainValue(mp_fine_gain_value == -1 ? os_atoh(ptr) : mp_fine_gain_value);
352 + ptr = prom_getenv("enable_margin_retrain");
354 ++ value = mp_enable_margin_retrain == -1 ? (ptr ? os_atoi(ptr) : 0) : mp_enable_margin_retrain;
358 +- value = os_atoi(ptr);
360 ++ dslhal_api_setMarginMonitorFlags(pIhw, 0, 1);
361 ++ bMarginRetrainEnable = 1;
362 ++ //printk("enable showtime margin monitor.\n");
365 ++ ptr = prom_getenv("margin_threshold");
366 ++ value = mp_margin_threshold == -1 ? (ptr ? os_atoi(ptr) : 0) : mp_margin_threshold;
370 +- dslhal_api_setMarginMonitorFlags(pIhw, 0, 1);
371 +- bMarginRetrainEnable = 1;
372 +- //printk("enable showtime margin monitor.\n");
374 +- ptr = prom_getenv("margin_threshold");
377 +- value = os_atoi(ptr);
378 +- //printk("Set margin threshold to %d x 0.5 db\n",value);
381 +- dslhal_api_setMarginThreshold(pIhw, value);
382 +- bMarginThConfig=1;
385 ++ dslhal_api_setMarginThreshold(pIhw, value);
386 ++ bMarginThConfig=1;
392 + ptr = prom_getenv("enable_rate_adapt");
394 ++ if(ptr || mp_enable_rate_adapt != -1)
396 +- dslhal_api_setRateAdaptFlag(pIhw, os_atoi(ptr));
397 ++ dslhal_api_setRateAdaptFlag(pIhw, mp_enable_rate_adapt == -1 ? os_atoi(ptr) : mp_enable_rate_adapt);
400 + // set powercutback
402 + ptr = prom_getenv("powercutback");
404 ++ if(ptr || mp_powercutback != -1)
406 +- dslhal_advcfg_onOffPcb(pIhw, os_atoi(ptr));
407 ++ dslhal_advcfg_onOffPcb(pIhw, mp_powercutback == -1 ? os_atoi(ptr) : mp_powercutback);
412 + ptr = prom_getenv("trellis");
414 ++ if(ptr || mp_trellis != -1)
416 +- dslhal_api_setTrellisFlag(pIhw, os_atoi(ptr));
417 +- trellis = os_atoi(ptr);
418 ++ trellis = mp_trellis == -1 ? os_atoi(ptr) : mp_trellis;
419 ++ dslhal_api_setTrellisFlag(pIhw, trellis);
420 + //printk("trellis=%d\n");
425 + ptr = prom_getenv("bitswap");
427 ++ if(ptr || mp_bitswap != -1)
429 + int offset[2] = {33, 0};
430 + unsigned int bitswap;
432 +- bitswap = os_atoi(ptr);
433 ++ bitswap = mp_bitswap == -1 ? os_atoi(ptr) : mp_bitswap;
435 + tn7dsl_generic_read(2, offset);
436 + dslReg &= dslhal_support_byteSwap32(0xFFFFFF00);
437 +@@ -2911,46 +2928,47 @@
438 + // maximum bits per carrier
440 + ptr = prom_getenv("maximum_bits_per_carrier");
442 ++ if(ptr || mp_maximum_bits_per_carrier != -1)
444 +- dslhal_api_setMaxBitsPerCarrierUpstream(pIhw, os_atoi(ptr));
445 ++ dslhal_api_setMaxBitsPerCarrierUpstream(pIhw, mp_maximum_bits_per_carrier == -1 ? os_atoi(ptr) : mp_maximum_bits_per_carrier);
448 + // maximum interleave depth
450 + ptr = prom_getenv("maximum_interleave_depth");
452 ++ if(ptr || mp_maximum_interleave_depth != -1)
454 +- dslhal_api_setMaxInterleaverDepth(pIhw, os_atoi(ptr));
455 ++ dslhal_api_setMaxInterleaverDepth(pIhw, mp_maximum_interleave_depth == -1 ? os_atoi(ptr) : mp_maximum_interleave_depth);
458 + // inner and outer pairs
460 + ptr = prom_getenv("pair_selection");
462 ++ if(ptr || mp_pair_selection != -1)
464 +- dslhal_api_selectInnerOuterPair(pIhw, os_atoi(ptr));
465 ++ dslhal_api_selectInnerOuterPair(pIhw, mp_pair_selection == -1 ? os_atoi(ptr) : mp_pair_selection);
469 + ptr = prom_getenv("dgas_polarity");
471 ++ if(ptr || mp_dgas_polarity != -1)
473 + dslhal_api_configureDgaspLpr(pIhw, 1, 1);
474 +- dslhal_api_configureDgaspLpr(pIhw, 0, os_atoi(ptr));
475 ++ dslhal_api_configureDgaspLpr(pIhw, 0, mp_dgas_polarity == -1 ? os_atoi(ptr) : mp_dgas_polarity);
479 + ptr = prom_getenv("los_alarm");
481 ++ if(ptr || mp_los_alarm != -1)
483 +- dslhal_api_disableLosAlarm(pIhw, os_atoi(ptr));
484 ++ dslhal_api_disableLosAlarm(pIhw, mp_los_alarm == -1 ? os_atoi(ptr) : mp_los_alarm);
488 + ptr = prom_getenv("eoc_vendor_id");
490 ++ if(ptr || mp_eoc_vendor_id != NULL)
492 ++ ptr = mp_eoc_vendor_id == NULL ? ptr : mp_eoc_vendor_id;
496 +@@ -2975,26 +2993,26 @@
499 + ptr = prom_getenv("eoc_vendor_revision");
501 ++ if(ptr || mp_eoc_vendor_revision != -1)
503 +- value = os_atoi(ptr);
504 ++ value = mp_eoc_vendor_revision == -1 ? os_atoi(ptr) : mp_eoc_vendor_revision;
505 + //printk("eoc rev=%d\n", os_atoi(ptr));
506 + dslhal_api_setEocRevisionNumber(pIhw, (char *)&value);
510 + ptr = prom_getenv("eoc_vendor_serialnum");
512 ++ if(ptr || mp_eoc_vendor_serialnum != NULL)
514 +- dslhal_api_setEocSerialNumber(pIhw, ptr);
515 ++ dslhal_api_setEocSerialNumber(pIhw, mp_eoc_vendor_serialnum == NULL ? ptr : mp_eoc_vendor_serialnum);
518 + // CQ10037 Added invntry_vernum environment variable to be able to set version number in ADSL2, ADSL2+ modes.
520 + ptr = prom_getenv("invntry_vernum");
522 ++ if(ptr || mp_invntry_vernum != NULL)
524 +- dslhal_api_setEocRevisionNumber(pIhw, ptr);
525 ++ dslhal_api_setEocRevisionNumber(pIhw, mp_invntry_vernum == NULL ? ptr : mp_invntry_vernum);
529 +@@ -3038,7 +3056,7 @@
530 + * backward compatibility.
532 + cp = prom_getenv("DSL_BIT_TMODE");
534 ++ if (cp || mp_dsl_bit_tmode != -1)
536 + printk("%s : env var DSL_BIT_TMODE is set\n", __FUNCTION__);
538 +@@ -3067,9 +3085,9 @@
540 + // UR8_MERGE_START CQ11054 Jack Zhang
541 + cp = prom_getenv("high_precision");
543 ++ if (cp || mp_high_precision != -1)
545 +- high_precision_selected = os_atoi(cp);
546 ++ high_precision_selected = mp_high_precision == -1 ? os_atoi(cp) : mp_high_precision;
548 + if ( high_precision_selected)
550 +diff -urN sangam_atm-07.02.01.00/tn7sar.c sangam_atm-07.02.01.00.mod/tn7sar.c
551 +--- sangam_atm-07.02.01.00/tn7sar.c 2007-09-19 04:12:20.000000000 +0200
552 ++++ sangam_atm-07.02.01.00.mod/tn7sar.c 2007-09-20 14:23:50.436500000 +0200
554 + /* PDSP Firmware files */
555 + #include "tnetd7300_sar_firm.h"
557 ++extern int mp_oam_lb_timeout;
558 ++extern int mp_autopvc_enable;
563 + pHalDev = (HAL_DEVICE *)priv->pSarHalDev;
565 + pauto_pvc = prom_getenv("autopvc_enable");
566 +- if(pauto_pvc) //CQ10273
567 ++ if(pauto_pvc || mp_autopvc_enable != -1) //CQ10273
569 +- auto_pvc =tn7sar_strtoul(pauto_pvc, NULL, 10);
570 ++ auto_pvc = mp_autopvc_enable == -1 ? tn7sar_strtoul(pauto_pvc, NULL, 10) : mp_autopvc_enable;
573 + memset(&chInfo, 0xff, sizeof(chInfo));
576 + /* read in oam lb timeout value */
577 + pLbTimeout = prom_getenv("oam_lb_timeout");
579 ++ if(pLbTimeout || mp_oam_lb_timeout != -1)
581 +- lbTimeout =tn7sar_strtoul(pLbTimeout, NULL, 10);
582 ++ lbTimeout = mp_oam_lb_timeout == -1 ? tn7sar_strtoul(pLbTimeout, NULL, 10) : mp_oam_lb_timeout;
583 + oamLbTimeout = lbTimeout;
584 + pHalFunc->Control(pHalDev,"OamLbTimeout", "Set", &lbTimeout);