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

Support for static and dynamic attrs as part of stormond implementation #439

Merged
merged 24 commits into from
May 30, 2024
Merged
Show file tree
Hide file tree
Changes from 23 commits
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
d9fd675
Added support for INNODISK SMART attributes
assrinivasan Oct 12, 2023
514ecb9
Fixed a bug with get_reserved_blocks() function
assrinivasan Oct 12, 2023
46417ec
Added support for Micron and Intel vendors. Fixed a bug with generic …
assrinivasan Oct 13, 2023
480a63f
Renamed ssd_base -> storage_base, added class for common calls, modif…
assrinivasan Feb 15, 2024
81d8cd2
Fixed a looping bug
assrinivasan Feb 15, 2024
48532ad
renamed sonic_ssd --> sonic_storage, removed 'ssd_' prefix from child…
assrinivasan Feb 17, 2024
1ff48af
Cleaned up impl per core algorithm changes, defined in HLD
assrinivasan May 11, 2024
a0bf842
Renamed SSD and EMMC UTs per naming convention
assrinivasan May 14, 2024
e35a73d
Made following changes based on prgeor review coments:
assrinivasan May 15, 2024
a678ae6
Added UTs, fixed bugs in ssd.py surfaced by UTs
assrinivasan May 20, 2024
3283abe
Added more UTs, fixed issue surafced by said UTs
assrinivasan May 21, 2024
a89e29c
Increased coverage, cleaned up SsdUtil
assrinivasan May 21, 2024
0a9c2b3
Added more UT coverage
assrinivasan May 22, 2024
eaa0ba0
Addressed review comments, changed UT accordingly
assrinivasan May 22, 2024
9eed062
Increased UT coverage
assrinivasan May 22, 2024
4de4038
Removed the underscore per naming convention
assrinivasan May 23, 2024
bf6213f
Fixed the following in ssd.py:
assrinivasan May 23, 2024
f866935
Fixed potential issue with parse_id_number not reconciling leading/tr…
assrinivasan May 24, 2024
67e5cae
Changed comment to better reflect class intent
assrinivasan May 25, 2024
0b95457
Fixed a bug where stormond was calling a function not defined for Emm…
assrinivasan May 25, 2024
4e5889f
Fixed fetch_parse_info error on emmc devices
assrinivasan May 27, 2024
21afe78
Added safeguards against vendor utilities failing
assrinivasan May 29, 2024
33cac81
switched from logger to syslogger per review
assrinivasan May 29, 2024
e2ce58d
Moved log to within class.
assrinivasan May 30, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
'sonic_platform_base',
'sonic_platform_base.sonic_eeprom',
'sonic_platform_base.sonic_sfp',
'sonic_platform_base.sonic_ssd',
'sonic_platform_base.sonic_storage',
'sonic_platform_base.sonic_pcie',
'sonic_platform_base.sonic_thermal_control',
'sonic_platform_base.sonic_xcvr',
Expand Down
267 changes: 0 additions & 267 deletions sonic_platform_base/sonic_ssd/ssd_generic.py
assrinivasan marked this conversation as resolved.
Show resolved Hide resolved

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,21 +1,22 @@
#
# ssd_emmc.py
# emmc.py
#
# Implementation of SSD Utility API for eMMC.
# It reads eMMC health, model, firmware, and serial from /sys/block/*.
#

try:
import os
from .ssd_base import SsdBase
from .storage_common import StorageCommon
except ImportError as e:
raise ImportError(str(e) + "- required module not found")


class EmmcUtil(SsdBase):
class EmmcUtil(StorageCommon):
def __init__(self, diskdev):
self.diskdev = diskdev
self.path = os.path.join('/sys/block', os.path.basename(diskdev))
StorageCommon.__init__(self, diskdev)

def _read_device_entry(self, entry, default=None):
path = os.path.join(self.path, 'device', entry)
Expand Down Expand Up @@ -49,3 +50,15 @@ def get_serial(self):

def get_vendor_output(self):
return ''

def get_disk_io_reads(self):
return 'N/A'

def get_disk_io_writes(self):
return 'N/A'

def get_reserved_blocks(self):
return 'N/A'

def fetch_parse_info(self, diskdev=None):
return
Loading
Loading