Commit Graph

165 Commits

Author SHA1 Message Date
roger530-ho
3740f1efb7
[Edgecore][device/accton] Fix subprocess.call issue in is_host(). (#13111)
Signed-off-by: roger530-ho <roger530_ho@edge-core.com>
2022-12-20 13:13:42 -08:00
Mai Bui
5b0c4ec1e6
[device/accton] Replace os.system and remove subprocess with shell=True (#11985)
Signed-off-by: maipbui <maibui@microsoft.com>
#### Why I did it
`subprocess.Popen()` and `subprocess.run()` is used with `shell=True`, which is very dangerous for shell injection.
`os` - not secure against maliciously constructed input and dangerous if used to evaluate dynamic content
#### How I did it
Replace `os` by `subprocess`
Remove unused functions
2022-11-07 10:31:32 -05:00
Hua Liu
cd33c7fc71
Replace swsssdk with swsscommon in accton device (#11348)
#### Why I did it
Update scripts in sonic-buildimage from py-swsssdk to swsscommon


#### How I did it
Remove unused swsssdk import from accton device code

#### How to verify it
Pass all E2E test case

#### Which release branch to backport (provide reason below if selected)

<!--
- Note we only backport fixes to a release branch, *not* features!
- Please also provide a reason for the backporting below.
- e.g.
- [x] 202006
-->

- [ ] 201811
- [ ] 201911
- [ ] 202006
- [ ] 202012
- [ ] 202106
- [ ] 202111
- [ ] 202205

#### Description for the changelog
Remove unused swsssdk import from accton device code

#### Link to config_db schema for YANG module changes
<!--
Provide a link to config_db schema for the table for which YANG model
is defined
Link should point to correct section on https://github.com/Azure/sonic-buildimage/blob/master/src/sonic-yang-models/doc/Configuration.md
-->

#### A picture of a cute animal (not mandatory but encouraged)
2022-08-24 12:36:47 +08:00
Polly Hsu
fe679ac965
[as7816-64x] Update to support DPB (Dynamic Port Breakout) (#10562)
Signed-off-by: polly_hsu polly_hsu@edge-core.com

Why I did it
Update to support as7816-64x DPB (Dynamic Port Breakout)

How I did it
Download the SONiC master image with commit, 64dc08a dated 2022-04-05 from SONiC Image Azure Pipelines
Update the file change of this PR accordingly

How to verify it
Set the default t1 topology configuration
Configure to breakout Ethernet0 from "1x100G[40G]" to "4x25G"
$ sudo config interface breakout Ethernet0 "4x25G" -f
Check the SONiC DBP interface status is expected
$ show interfaces status
2022-06-30 12:29:11 -07:00
jostar-yang
b86499ccb9
[PDDF] Rename temp for as7816/7326/7726 (#10609)
* [PDDF] Rename temp for 7816/7326/7726

Signed-off-by: Jostar Yang <jostar_yang@accton.com.tw>

* Change naming to pddf device

Co-authored-by: Jostar Yang <jostar_yang@accton.com.tw>
2022-05-09 10:47:45 -07:00
Polly Hsu
a1e76d25b7
[as7816-64x] Update installer.conf (#10418)
Co-authored-by: ecsonic <ecsonic@edge-core.com>
Why I did it
The customer report of the PCIe Bus Errors upon the SDK initialization of as7816-64x.

How I did it
Based on the internal info and discussion, update "pcie_aspm=off" into ONIE_PLATFORM_EXTRA_CMDLINE_LINUX of installer.conf to resolve it.
2022-05-02 11:09:16 -07:00
brandonchuang
2116f62978
[AS9716-32D] Support i2c mux reset (#10492)
Why I did it
    Prevent from i2c bus to get locked.

How I did it
    Add sysfs driver to access ioport.
    Command to reset i2c mux:
    echo 1 > /sys/devices/platform/as9716_32d_ioport/i2c_mux_rst
    Command to bring i2c mux out of reset:
    echo 0 > /sys/devices/platform/as9716_32d_ioport/i2c_mux_rst

Signed-off-by: Brandon Chuang <brandon_chuang@edge-core.com>
2022-04-09 10:51:49 -07:00
jostar-yang
b39b7a3f2d
[Accton/PDDF] Support pddf to as4630/as7816/as7326 (#10340)
Why I did it
Support pddf to as4630/as7816/as7326

How I did it
Send needed file to the PR for these platform

How to verify it
Test sensors and show platform cmd.
root@as7326-56x-3:/home/admin# show platform psustatus
PSU Model Serial HW Rev Voltage (V) Current (A) Power (W) Status LED

PSU 1 FSF045-611 FSF0451912000505 N/A 12.06 5.50 66.00 OK green
PSU 2 FSF045-611 FSF0451912000568 N/A 12.00 5.50 66.00 OK green

root@as7326-56x-3:/home/admin# sensors
lm75-i2c-15-4a
Adapter: i2c-1-mux (chan_id 6)
Main Board Temperature: +35.5 C (high = +80.0 C, hyst = +75.0 C)

lm75-i2c-15-4b
Adapter: i2c-1-mux (chan_id 6)
CPU Board Temperature: +29.0 C (high = +80.0 C, hyst = +75.0 C)

fan_ctrl-i2c-11-66
Adapter: i2c-1-mux (chan_id 2)
fan1: 9100 RPM
fan2: 9400 RPM
fan3: 9300 RPM
fan4: 9600 RPM
fan5: 9000 RPM
fan6: 9100 RPM
fan7: 9100 RPM
fan8: 9300 RPM
fan9: 9200 RPM
fan10: 9400 RPM
fan11: 9200 RPM
fan12: 9400 RPM

pch_haswell-virtual-0
Adapter: Virtual device
temp1: +43.0 C

psu_pmbus-i2c-17-59
Adapter: i2c-1-mux (chan_id 0)
in3: +12.06 V
fan1: 6272 RPM
temp1: +37.0 C
power2: 60.00 W
curr2: +6.00 A

lm75-i2c-15-49
Adapter: i2c-1-mux (chan_id 6)
Main Board Temperature: +40.0 C (high = +80.0 C, hyst = +75.0 C)

lm75-i2c-15-48
Adapter: i2c-1-mux (chan_id 6)
Main Board Temperature: +39.0 C (high = +80.0 C, hyst = +75.0 C)

psu_pmbus-i2c-13-5b
Adapter: i2c-1-mux (chan_id 4)
in3: +12.00 V
fan1: 6144 RPM
temp1: +36.0 C
power2: 66.00 W
curr2: +5.50 A

coretemp-isa-0000
Adapter: ISA adapter
Package id 0: +50.0 C (high = +82.0 C, crit = +104.0 C)
Core 0: +50.0 C (high = +82.0 C, crit = +104.0 C)
Core 1: +50.0 C (high = +82.0 C, crit = +104.0 C)
Core 2: +50.0 C (high = +82.0 C, crit = +104.0 C)
Core 3: +50.0 C (high = +82.0 C, crit = +104.0 C)

Signed-off-by: Jostar Yang <jostar_yang@accton.com.tw>
2022-04-01 09:55:04 -07:00
jostar-yang
7debcffe62
[Accton/PDDF] Enable thermalctld in pmon (#9982)
When do "skip_thermalcltd: true" will let "show platform fan" and "show platform temp" fail.
When enable thermalctld, these cmd will work well.

Signed-off-by: Jostar Yang <jostar_yang@accton.com.tw>
2022-03-29 13:35:42 -07:00
Jeff Henning
ad6200029f
Edgecore 4630/5835/7326/7816 API2.0 platform support (#10053)
* Initial pass of EdgeCore platform changes.

* Remove libevent dependency from lldpd.

* Remove python2 dependencies python3.7 force from platform install script.

* Include usbmount support changes.

* Add missing 4630 install file.

* Update a few file permissions.  Add umask line to Makefile.  Specify python3.9 in install script.

* Misc platform updates:
- Add missing fan drawer component to sonic_platform
- Remove kernel version specification from Makefile
- Update to 4630 utility

* - Fix file permissions on source files
- Fix compile issue with 4630 driver modules (set_fs, get_fs, no longer supported in kernel 5.10)

* Fix missing/extra parens in 4630 util script.

* Fix indentation in fanutil.py.

* Integrate deltas from Edgecore to ec_platform branch.

* Installer update from Edgecore to resolve smbus serial console errors.

* Update stable_size for warm boot.

* Fix SFP dictionary key to match xcvrd.

* - Add missing define in event.py files needed for xcvrd
- Fix SFP info dict key for 7xxx switches

* 5835 platform file updates including installer and 5835 utility.

* 5835 fix for DMAR errors on serial console.

* Don't skip starting thermalctld in the pmon container.

* Revert several changes that were not related to platform.

* Run thermalctld in pmon container.

* Don't disable thermalctld in the pmon container.

* Fix prints/parens in 7816 install utility.

* - Incorporate 7816 changes from Edgecore
- Fix 7326 driver file using old kernel function

* Update kernel modules to use kernel_read().

* Fix compile errors with 7816 and 7326 driver modules.

* Fix some indents preventing platform files from loading.

* Update 7816 platform sfp dictionary to match field names in xcvrd.

* Add missing service and util files for 7816.

* Update file names, etc. based on full SKU for 7816.

* Delete pddf files not needed.  These were causing conflicts with API2.0
implementation.

* Remove pddf files suggested by Edgecore that were preventing API2.0 support from starting.

* Install API2.0 file instead of pddf.

* Update 7326 mac service file to not use pddf.  Fix syntax errors in 7326 utility script.

* Fix sonic_platform setup file for 7326.

* Fix syntax errors in python scripts.

* Updates to 7326 platform files.

* Fix some tab errors pulled down from master merge.

* Remove pddf files that were added from previous merge.

* Updates for 5835.

* Fix missing command byte for 5835 psu status.

* Fix permission bits on 4630 service files.

* Update platforms to use new SFP refactoring.

* Fix unused var warnings.
2022-03-18 06:17:08 +05:30
Kostiantyn Yarovyi
bf5f9c2918
[BFN] Update configuration files (#9913)
* [Barefoot] update switch-tna-sai.conf file

* remove deprecated conf files

* [Barefoot] update switch-tna-sai.conf file for Accton wedge100bf_32qs platform

* pdated switch-tna-sai.conf
2022-03-09 09:57:08 +05:30
jostar-yang
d959c4adcd
[AS4630-54PE] Fix led drv and i2c bus order (#9170)
Signed-off-by: Jostar Yang jostar_yang@accton.com.tw

Why I did it
Fix led drv because CPLD SPEC is updated.
Fix i2c bus order
How I did it
Fix led drv. Set blacklist to i801 and ismt. Let accton util to modprobe i801 and ismt.

How to verify it
Test led and sensors cmd. Results are fine.
2022-03-04 17:40:27 -08:00
jostar-yang
85976cbca3
[AS5835-54X] Fix I2C bus order (#9146)
Why I did it
To fix I2C bus order to meet with HW SPEC. Let i801 use bus-0 and ismt use bus-1

How I did it
Modprobe i801 and then do ismt. So i801 will use bus-0 and ismt will use bus-1.

How to verify it
Test show cmd and sensors work well

Co-authored-by: Jostar Yang <jostar_yang@accton.com.tw>
2022-03-04 17:33:50 -08:00
jostar-yang
34a4817ad0
[AS7712/PDDF] Add idle_state=-2 for pca954x deselect (#10079)
Signed-off-by: Jostar Yang jostar_yang@accton.com.tw

Why I did it
Linux kernel 5.10, 'force_deselct_on_exit' parameter used for driver i2c_mux_pca954x is no longer valid. Instead an attribute 'idle_state' is added per MUX device. So set idle_state=-2 will let do deselect to pca954 when device channel exit . To avoid cause another device channel access i2c fail.

How I did it
Remove force_deselect_on_exit because not use this parameter.
Add "idle_state":"-2" to each "virt_bus"
How to verify it
Test all sysfs are fine.
2022-03-03 15:50:41 -08:00
alvinkaiwei
d2f6fe7463
Add support for Accton wedge100bf_32qs platform to SONiC master (#9257)
* Add support for Accton wedge100bf_32qs platform

This pull request is based on wedge100bf_32x.

The components on the mainboard are the same as wedge100bf_32x, except for tofino 32Q and COMe models, so it refers to wedge100bf_32x to create new model: wedge100bf_32qs.

Signed-off-by: alvin_feng <alvin_feng@accton.com>

* Fix lgtm alerts issues

Signed-off-by: alvin_feng <alvin_feng@accton.com>

* Modify some file permissions and use symlink to link wedge100bf-32qs/sonic_platform

Signed-off-by: alvin_feng <alvin_feng@accton.com>

* Remove switch-sai.conf file

Signed-off-by: alvin_feng <alvin_feng@accton.com>

* Modify platform.json to avoid platform TCs issues and changes for correct generating BUFFER_QUEUE values in DB.

Signed-off-by: alvin_feng <alvin_feng@accton.com>

* Fix error name in platform.json
2022-02-18 15:21:14 +05:30
SeanWu
7e89fad5d1
[AS4630-54TE] Fixes to sfp.py for sfputil usage (#8985)
* Fix KeyError exception while sfputil show eeprom.
* Implement reset/lpmode related APIs, which need PR8115's sysfs.
* Fix EEPROM byte offset in several APIs
* Fix typos
* Implement get_position_in_parent() and is_replaceable()

Signed-off-by: Sean Wu <sean_wu@edge-core.com>
2022-02-14 07:59:26 +05:30
jostar-yang
519dcde939
[AS7712-32X] Add to support PDDF (#8040)
* [AS7712-32X] Add to support PDDF

Signed-off-by: Jostar Yang <jostar_yang@accton.com.tw>

* Fix LGTM alerts

* Fix AS7712-32X xcvrd busy issue

Co-authored-by: Jostar Yang <jostar_yang@accton.com.tw>
2022-02-10 22:09:50 +05:30
jostar-yang
f9a29ef056
[AS4630-54PE] Add to support PDDF (#8014)
* [AS4630-54PE] Add to support PDDF

Signed-off-by: Jostar Yang <jostar_yang@accton.com.tw>

* Fix LGTM alerts

* Fix LGTM alerts

* Fix  LGTM alerts

* Add post_device.sh to turn off stk led

* Add to support system_health

* Correct the wait and timeout mechanism for better CPU usage

* Add event.c to support port evt change

Co-authored-by: Jostar Yang <jostar_yang@accton.com.tw>
2022-02-10 22:09:05 +05:30
gechiang
ddfe87a71a
[BRCMSAI 6.0.0.13-1] Fix Cancun file directory at new location causing TD3 platform boot issue (#9922) 2022-02-07 08:56:06 -08:00
jostar-yang
9c5f38b9f3
[AS7726-32X] Add to support mulit PSU SN in PDDF (#8164)
* [AS7726-32X] Add to support mulit PSU in PDDF

Signed-off-by: Jostar Yang <jostar_yang@accton.com.tw>

* Modify SN offset and include path

* Fix device_name to PSU2-EEPROM in PSU2

Co-authored-by: Jostar Yang <jostar_yang@accton.com.tw>
2022-02-07 22:03:11 +05:30
SeanWu
a2d1798a11
[AS7315-27XB] Fix build error and incorrect I2C bus number (#9712)
* Add intel_iommu=off to installer.conf

* This solve flooding DMAR err msg: "handling fault status reg 2"

Signed-off-by: Sean Wu <sean_wu@edge-core.com>

* remove customized at24 driver

* Use kernel 5.10.46 upstream at24 driver directly. The ADDR16 issue on
old driver has gone.

Signed-off-by: Sean Wu <sean_wu@edge-core.com>

* pin I2C-0/I2C-1 bus order

* otherwise, sometimes I2C-0/I2C-1 will be assigned to the undesired one.

Signed-off-by: Sean Wu <sean_wu@edge-core.com>

* fix i2c bus num for fan driver

Signed-off-by: Sean Wu <sean_wu@edge-core.com>

* backward compatible with R0A/R0B HW

Signed-off-by: Sean Wu <sean_wu@edge-core.com>
2022-01-16 12:13:16 +05:30
SeanWu
a5515b5297
[Accton] Enable pca954x i2c mux idle_disconnect for 5.10 kernel (#9745)
Enable pca954x idle_disconnect to avoid possible I2C device address conflict.

How I did it
Change pca954x device_attr idle_state to -2 (MUX_IDLE_DISCONNECT).

How to verify it
Cat pca954x device_attr idle_state and confirm the value is -2.

Signed-off-by: Sean Wu <sean_wu@edge-core.com>
2022-01-12 13:43:47 -08:00
Aravind Mani
ac2885a988
[SFP-Refactor] Modify transceiver key name (#9447)
* Modify transceiever key name

* fix alignment
2021-12-09 12:38:45 +05:30
Qi Luo
add9b651b6
Add platform_asic file to each platform folder in sonic-device-data based package (#8542)
#### Why I did it
Add platform_asic file to each platform folder in sonic-device-data package. The file content will be used as the ground truth of mapping from PLATFORM_STRING to switch ASIC family.

One use case of the mapping is to prevent installing a wrong image, which targets for other ASIC platforms. For example, currently we have several ONIE images naming as sonic-*.bin, it's easy to mistakenly install the wrong image. With this mapping built into image, we could fetch the ONIE platform string, and figure out which ASIC it is using, and check we are installing the correct image.

After this PR merged, each platform vendor has to add one mandatory text file  `device/PLATFORM_VENDOR/PLATFORM_STRING/platform_asic`, with the content of the platform's switch ASIC family.

I will update https://github.com/Azure/SONiC/wiki/Porting-Guide after this PR is merged.

You can get a list of the ASIC platforms by `ls -b platform | cat`. Currently the options are
```
barefoot
broadcom
cavium
centec
centec-arm64
generic
innovium
marvell
marvell-arm64
marvell-armhf
mellanox
nephos
p4
vs
```

Also support
```
broadcom-dnx
```

#### How I did it

#### How to verify it
Test one image on DUT. And check the folders under `/usr/share/sonic/device`
2021-10-08 19:27:48 -07:00
Ashok Daparthi-Dell
6cbdf11e53
SONIC QOS YANG - Remove qos tables field value refernce format (#7752)
Depends on Azure/sonic-utilities#1626
Depends on Azure/sonic-swss#1754

QOS tables in config db used ABNF format i.e "[TABLE_NAME|name] to refer fieldvalue to other qos tables.

Example:
Config DB:
"Ethernet92|3": {
"scheduler": "[SCHEDULER|scheduler.1]",
"wred_profile": "[WRED_PROFILE|AZURE_LOSSLESS]"
},
"Ethernet0|0": {
"profile": "[BUFFER_PROFILE|ingress_lossy_profile]"
},
"Ethernet0": {
"dscp_to_tc_map": "[DSCP_TO_TC_MAP|AZURE]",
"pfc_enable": "3,4",
"pfc_to_queue_map": "[MAP_PFC_PRIORITY_TO_QUEUE|AZURE]",
"tc_to_pg_map": "[TC_TO_PRIORITY_GROUP_MAP|AZURE]",
"tc_to_queue_map": "[TC_TO_QUEUE_MAP|AZURE]"
},

This format is not consistent with other DB schema followed in sonic.
And also this reference in DB is not required, This is taken care by YANG "leafref".

Removed this format from all platform files to consistent with other sonic db schema.
Example:
"Ethernet92|3": {
"scheduler": "scheduler.1",
"wred_profile": "AZURE_LOSSLESS"
},

Dependent pull requests:
#7752 - To modify platfrom files
#7281 - Yang model
Azure/sonic-utilities#1626 - DB migration
Azure/sonic-swss#1754 - swss change to remove ABNF format
2021-09-28 09:21:24 -07:00
jostar-yang
76ed66ca29
[AS4630-54PE] Add SFP reset and lpmode sysfs (#8450)
Add QSFP reset and lpmode sysfs

Signed-off-by: Jostar Yang <jostar_yang@accton.com.tw>
2021-08-14 23:58:17 -07:00
SeanWu
fed8957b47
[Accton] AS4630-54TE Support SystemHealthMonitor (#8183)
1. Implement FanDrawer-Fan hierarchy.
2. Enable thermalctld, disable pcied.
3. Implement SystemLED in Chassis.
4. Correct Fan direction
5. Implement require Fan APIs for SystemHealthMonitoring.
6. Handle non-ascii character while reading PSU model/serial num.

```
Check if System-health can pass the check and display the SystemLED correctly.


///////// booting, DIAG_LED = GREEN_BLINKING /////////

root@sonic:/tmp# show system-health detail 
System is currently booting...
root@sonic:/tmp# cat /sys/class/leds/diag/brightness 
5


///////// container_checker fail, DIAG_LED = AMBER /////////

root@sonic:/sys/bus/i2c/devices# show system-health detail
System status summary

  System status LED  STATUS_LED_COLOR_AMBER
  Services:
    Status: OK
  Hardware:
    Status: Not OK
    Reasons: container_checker is not Status ok

System services and devices monitor list

Name                        Status    Type
--------------------------  --------  ----------
container_checker           Not OK    Program
sonic                       OK        System
rsyslog                     OK        Process
root-overlay                OK        Filesystem
var-log                     OK        Filesystem
routeCheck                  OK        Program
diskCheck                   OK        Program
container_memory_telemetry  OK        Program
FAN-1F                      OK        Fan
FAN-1R                      OK        Fan
FAN-2F                      OK        Fan
FAN-2R                      OK        Fan
FAN-3F                      OK        Fan
FAN-3R                      OK        Fan
PSU-1 FAN-1                 OK        Fan
PSU-2 FAN-1                 OK        Fan
PSU 1                       OK        PSU
PSU 2                       OK        PSU

System services and devices ignore list

Name             Status    Type
---------------  --------  ------
asic             Ignored   Device
psu.temperature  Ignored   Device

///////// skip container_checker, DIAG_LED = GREEN /////////

root@sonic:/sys/bus/i2c/devices# vi /usr/share/sonic/device/x86_64-accton_as4630_54te-r0/system_health_monitoring_config.json 
root@sonic:/sys/bus/i2c/devices# 
root@sonic:/sys/bus/i2c/devices# 
root@sonic:/sys/bus/i2c/devices# show system-health detail
System status summary

  System status LED  STATUS_LED_COLOR_GREEN
  Services:
    Status: OK
  Hardware:
    Status: OK

System services and devices monitor list

Name                        Status    Type
--------------------------  --------  ----------
sonic                       OK        System
rsyslog                     OK        Process
root-overlay                OK        Filesystem
var-log                     OK        Filesystem
routeCheck                  OK        Program
diskCheck                   OK        Program
container_memory_telemetry  OK        Program
FAN-1F                      OK        Fan
FAN-1R                      OK        Fan
FAN-2F                      OK        Fan
FAN-2R                      OK        Fan
FAN-3F                      OK        Fan
FAN-3R                      OK        Fan
PSU-1 FAN-1                 OK        Fan
PSU-2 FAN-1                 OK        Fan
PSU 1                       OK        PSU
PSU 2                       OK        PSU

System services and devices ignore list

Name               Status    Type
-----------------  --------  -------
container_checker  Ignored   Service
psu.temperature    Ignored   Device
asic               Ignored   Device
```


Signed-off-by: Sean Wu <sean_wu@edge-core.com>
2021-07-24 16:27:34 -07:00
chihhan123
2a06e079fa
[accton]: Support LED (1G) on AS7326-56X (#8185)
Modify micro code of custom_led.bin to support LED 1G
2021-07-16 07:47:05 -07:00
jostar-yang
b2c74afeb5
[AS5835-54x] Add get_status api and fix bug to fan.py (#7784)
Add get_status api and fix for read fan direction sysfs to fan.py

Signed-off-by: Jostar Yang <jostar_yang@accton.com.tw>
2021-06-03 08:43:26 -07:00
jostar-yang
0c5c4872dc
[as5835-54x] Add to support API2.0 (#6480)
Add platform API 2.0 support for as5835-54x platform
2021-05-28 10:50:49 -07:00
SeanWu
9b4ed6e6df
[accton] Add sensors.conf to multiple models (#7494)
#### Why I did it
Improve readability of `show environment` output.

#### How I did it
In all sensors.conf, give the customized labels according to HW specifications for each model.

Signed-off-by: Sean Wu <sean_wu@edge-core.com>
2021-05-12 12:42:20 -07:00
ec-michael-shih
a070f1a239
[Platform] Accton add to support as9726-32d platform. (#7479)
Add support for Accton as9726-32d platform

This pull request is based on as9716-32d, so I reference as9716-32d to create new model: as9726-32d.
This module do not need led driver to control led, FPGA can handle it.
I also implement API2.0(sonic_platform) for this model, CPLD driver, PSU driver, Fan driver to control these HW behavior.
2021-05-11 19:06:36 -07:00
jostar-yang
93ceb3933e
[as7726-32x] Support PDDF (#7398)
Add PDDF support for Accton as7726-32x platform

Signed-off-by: Jostar Yang <jostar_yang@accton.com.tw>
2021-04-27 11:01:40 -07:00
dereksun01
3b4aa00e26
[device] Add as5835_54x configuration (#6970)
Add configuration files:
- mv2-as5835-48x10G+6x100G.config.bcm
- sai.profile
- led_proc_init.soc
- custom_led.bin

Signed-off-by: derek_sun <ecsonic@edge-core.com>
2021-04-19 08:56:12 -07:00
jostar-yang
ee728aab7b
[as7326-56x] Add to support PDDF (#7176)
Support PDDF on the as7326-56x platfrom

Signed-off-by: Jostar Yang <jostar_yang@accton.com.tw>
2021-04-15 09:39:15 -07:00
jostar-yang
6641a6b1a1
[as9716-32d] Add to support PDDF (#6902)
Add PDDF support for Accton as9716-32d platform

Co-authored-by: Jostar Yang <jostar_yang@accton.com.tw>
2021-04-14 14:43:52 -07:00
jostar-yang
b4b9e4234f
[as7816-64x] Add to support PDDF (#7077)
Add PDDF support for Accton as7816-64x platform

Co-authored-by: Jostar Yang <jostar_yang@accton.com.tw>
2021-04-14 14:40:52 -07:00
Dmytro Shevchuk
d8627e6414
[yang] update yang model, add autoneg to sonic-port (#5963)
Dynamic Port Breakout fall in case "autoneg" field exist in config_db.

- How I did it
Added "autoneg" field in sonic-port yang model.

- How to verify it
Add "autoneg" field into config_db like this:

"Ethernet8": {
    "index": "2", 
    "lanes": "8,9,10,11", 
    "fec": "rs", 
    "pfc_asym": "off", 
    "mtu": "9100", 
    "alias": "Ethernet8", 
    "admin_status": "up", 
    "autoneg": "on", 
    "speed": "100000",
},
2021-03-30 08:27:58 -07:00
ec-michael-shih
66e3e51f70
[Platform] Accton add to support as4630-54te platform. (#6683)
Add support for Accton as4630-54te platform
2021-02-25 10:47:38 -08:00
Joe LeVeque
7ea0d9e27a
[sonic-platform-common] Update submodule (#6742)
Submodule commits included:

* src/sonic-platform-common 6ad0004...bd4dc03 (1):
  > [sonic_sfp/qsfp_dd.py] Update DOM capability method name to align with other drivers (#163)

Also align all calling function names to match.
2021-02-10 06:12:49 -08:00
jostar-yang
c54a03fade
[as7312-54x] Support platform API2.0 (#6272)
Add platform 2.0 support for Accton as7312-54x platform
2021-02-09 10:02:09 -08:00
Joe LeVeque
18f2c5cfdd
[platform] Update QSFP method name 'parse_qsfp_dom_capability' -> 'parse_dom_capability' (#6695)
**- Why I did it**
PR https://github.com/Azure/sonic-platform-common/pull/102 modified the name of the SFF-8436 (QSFP) method to align the method name between all drivers, renaming it from `parse_qsfp_dom_capability` to `parse_dom_capability`. Once the submodule was updated, the callers using the old nomenclature broke. This PR updates all callers to use the new naming convention.

**- How I did it**

Update the name of the function globally for all calls into the SFF-8436 driver.

Note that the QSFP-DD driver still uses the old nomenclature and should be modified similarly. I will open a PR to handle this separately.
2021-02-05 14:41:05 -08:00
dereksun01
ca355037f6
[device] Add as4630_54pe SDK configuration parameters (#5167)
**- Why I did it**
- Add as4630_54pe SDK configuration parameters.

**- How I did it**
- Add  l3_alpm_enable=2 and ipv6_lpm_128b_enable=1 in hx5-as4630-48x1G+4x25G+2x100G.bcm.

Co-authored-by: derek_sun <derek_sun@edge-core>
Co-authored-by: derek_sun <ecsonic@edge-core.com>
2021-02-04 10:51:12 -08:00
gechiang
c98e8d6690
[BCM Config] Update TD3 bcm.config files to use ISSU capable premium CANCUN 6.4.1 (#6651) 2021-02-02 21:48:26 -08:00
Mahesh Maddikayala
908884b0e8
[broadcom]: Add BCM config variable that contains premier cancun firmware path (#6611)
BRCM SDK 6.5.21 includes firmware updates (premier cancun) for TD3 platforms. The firmware update is required on TD3 platforms, which is packaged with BCMSAI 4.3.0.10.

**- How I did it**

Updated BCM config with a new variable that specifies the firmware package path. SDK uses this path to locate firmware packages and load during cold boot.

**- How to verify it**

 
bsv
BRCM SAI ver: [4.3.0.10], OCP SAI ver: [1.7.1], SDK ver: [sdk-6.5.21] CANCUN ver: [5.3.3]
drivshell>
admin@str2-7050cx3-acs-02:~$ bcmsh
Press Enter to show prompt.
Press Ctrl+C to exit.
NOTICE: Only one bcmsh or bcmcmd can connect to the shell at same time.
 
 
drivshell>cancun stat
cancun stat
UNIT0 CANCUN:
        CIH: LOADED
        Ver: 06.06.01
 
        CMH: LOADED
        Ver: 06.06.01
        SDK Ver: 06.05.21
 
        CCH: LOADED
       Ver: 06.06.01
        SDK Ver: 06.05.21
 
        CEH: LOADED
        Ver: 06.06.01
        SDK Ver: 06.05.21
 
drivshell>
2021-01-30 14:41:17 -08:00
Joe LeVeque
7f4ab8fbd8
[sonic-utilities] Update submodule; Build and install as a Python 3 wheel (#5926)
Submodule updates include the following commits:

* src/sonic-utilities 9dc58ea...f9eb739 (18):
  > Remove unnecessary calls to str.encode() now that the package is Python 3; Fix deprecation warning (#1260)
  > [generate_dump] Ignoring file/directory not found Errors (#1201)
  > Fixed porstat rate and util issues (#1140)
  > fix error: interface counters is mismatch after warm-reboot (#1099)
  > Remove unnecessary calls to str.decode() now that the package is Python 3 (#1255)
  > [acl-loader] Make list sorting compliant with Python 3 (#1257)
  > Replace hard-coded fast-reboot with variable. And some typo corrections (#1254)
  > [configlet][portconfig] Remove calls to dict.has_key() which is not available in Python 3 (#1247)
  > Remove unnecessary conversions to list() and calls to dict.keys() (#1243)
  > Clean up LGTM alerts (#1239)
  > Add 'requests' as install dependency in setup.py (#1240)
  > Convert to Python 3 (#1128)
  > Fix mock SonicV2Connector in python3: use decode_responses mode so caller code will be the same as python2 (#1238)
  > [tests] Do not trim from PATH if we did not append to it; Clean up/fix shebangs in scripts (#1233)
  > Updates to bgp config and show commands with BGP_INTERNAL_NEIGHBOR table (#1224)
  > [cli]: NAT show commands newline issue after migrated to Python3 (#1204)
  > [doc]: Update Command-Reference.md (#1231)
  > Added 'import sys' in feature.py file (#1232)

* src/sonic-py-swsssdk 9d9f0c6...1664be9 (2):
  > Fix: no need to decode() after redis client scan, so it will work for both python2 and python3 (#96)
  > FieldValueMap `contains`(`in`)  will also work when migrated to libswsscommon(C++ with SWIG wrapper) (#94)

- Also fix Python 3-related issues:
    - Use integer (floor) division in config_samples.py (sonic-config-engine)
    - Replace print statement with print function in eeprom.py plugin for x86_64-kvm_x86_64-r0 platform
    - Update all platform plugins to be compatible with both Python 2 and Python 3
    - Remove shebangs from plugins files which are not intended to be executable
    - Replace tabs with spaces in Python plugin files and fix alignment, because Python 3 is more strict
    - Remove trailing whitespace from plugins files
2020-11-25 10:28:36 -08:00
Roy Lee
ce6286eb84
[device/accton] Remove the use of python pickle package (#5475)
Pickle is applied to save the order of i2c adapters at installation.
With pickle removed, it just checks the order of i2c buses every time it needs.
2020-11-04 16:24:53 -08:00
Joe LeVeque
8011edc307
[platform] Remove references to deprecated get_serial_number() method in Chassis class (#5649)
The `get_serial_number()` method in the ChassisBase and ModuleBase classes was redundant, as the `get_serial()` method is inherited from the DeviceBase class. This method was removed from the base classes in sonic-platform-common and the submodule was updated in https://github.com/Azure/sonic-buildimage/pull/5625.

This PR aligns the existing vendor platform API implementations to remove the `get_serial_number()` methods and ensure the `get_serial()` methods are implemented, if they weren't previously.

Note that this PR does not modify the Dell platform API implementations, as this will be handled as part of https://github.com/Azure/sonic-buildimage/pull/5609
2020-10-17 22:00:14 -07:00
jostar-yang
a92986c605
[as7326-56x]Fix port_eeprom i2c mapping (#5466)
**- Why I did it**
There is error i2c mapping for port 11,12 and port 19, 20. 

**- How I did it**
Fix to correct i2c mapping

Co-authored-by: Jostar Yang <jostar_yang@accton.com.tw>
2020-09-26 11:21:31 -07:00
abdosi
a6a10f05b7
In SAI 3.5 by default we are supporting 256 Group with 64 Memeber each. (#5400)
However in SAI 3.7 default behaviout got changes to 128 Group and 128
    Memeber each.

    This change is to make sure we are using same ECMP Group/Memeber Per
    Group for 3.7 also so that behaviour is consistent.

Signed-off-by: Abhishek Dosi <abdosi@microsoft.com>
2020-09-22 11:21:12 -07:00