Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Micas/Platform]platform support M2-W6920-32QC2X #16912

Draft
wants to merge 2 commits into
base: 202111
Choose a base branch
from

Conversation

philo-micas
Copy link

Why I did it

Work item tracking
  • Microsoft ADO (number only):

How I did it

How to verify it

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

  • 201811
  • 201911
  • 202006
  • 202012
  • 202106
  • 202111
  • 202205
  • 202211
  • 202305

Tested branch (Please provide the tested image version)

Description for the changelog

Link to config_db schema for YANG module changes

A picture of a cute animal (not mandatory but encouraged)

Signed-off-by: philo <philo@micasnetworks.com>
Signed-off-by: philo <philo@micasnetworks.com>
@@ -0,0 +1,135 @@
#!/usr/bin/python
# -*- coding: utf-8 -*-
import sys

Check notice

Code scanning / CodeQL

Unused import Note

Import of 'sys' is not used.
#!/usr/bin/python
# -*- coding: utf-8 -*-
import sys
import os

Check notice

Code scanning / CodeQL

Unused import Note

Import of 'os' is not used.
try:
import time
import commands
import re

Check notice

Code scanning / CodeQL

Unused import Note

Import of 're' is not used.
import commands
import re
import os
import threading

Check notice

Code scanning / CodeQL

Unused import Note

Import of 'threading' is not used.
try:
file_path.seek(offset)
read_buf = file_path.read(num_bytes)
except:

Check notice

Code scanning / CodeQL

Except block handles 'BaseException' Note

Except block directly handles BaseException.
try:
for n in range(0, num_bytes):
eeprom_raw[n] = hex(ord(raw[n]))[2:].zfill(2)
except:

Check notice

Code scanning / CodeQL

Except block handles 'BaseException' Note

Except block directly handles BaseException.

def decode(self, e2):
# header
e2_index = 0

Check notice

Code scanning / CodeQL

Unused local variable Note

Variable e2_index is not used.
return 0

def _get_port_eeprom_path(self, port_num, devid):
sysfs_i2c_adapter_base_path = "/sys/class/i2c-adapter"

Check warning

Code scanning / CodeQL

Variable defined multiple times Warning

This assignment to 'sysfs_i2c_adapter_base_path' is unnecessary as it is
redefined
before this value is used.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant