mirror of
https://github.com/tuxbox-fork-migrations/recycled-ni-neutrino.git
synced 2025-09-01 18:01:06 +02:00
imageinfo_ni: simplify max_bit handling
Origin commit data
------------------
Commit: d04afd80ba
Author: vanhofen <vanhofen@gmx.de>
Date: 2017-03-03 (Fri, 03 Mar 2017)
Origin message was:
------------------
- imageinfo_ni: simplify max_bit handling
This commit is contained in:
@@ -138,8 +138,7 @@ void CImageInfoNI::Init(void)
|
||||
}
|
||||
offset = offset + OFFSET_INNER_MID;
|
||||
|
||||
netIfName = "eth0";
|
||||
netMaxBit = 104857600;
|
||||
netIfName = "eth0"; //FIXME; What about the other ports?
|
||||
}
|
||||
|
||||
CImageInfoNI::~CImageInfoNI()
|
||||
@@ -858,16 +857,10 @@ void CImageInfoNI::paint_NET_Info(int posx, int posy)
|
||||
* 13107200 Byte
|
||||
* 104857600 Bit
|
||||
*/
|
||||
#ifdef HAVE_GENERIC_HARDWARE
|
||||
int max_bit = netMaxBit; /* PC */
|
||||
#else
|
||||
# ifdef BOXMODEL_CS_HD2
|
||||
int max_bit = 104857600; /* Shiner, Kronos */
|
||||
if (revision == 9)
|
||||
max_bit = 1073741824; /* Apollo */
|
||||
# else ifdef
|
||||
int max_bit = 104857600;
|
||||
# endif
|
||||
#ifdef BOXMODEL_CS_HD2
|
||||
if (revision == 9) /* Apollo */
|
||||
max_bit = 1073741824;
|
||||
#endif
|
||||
int percent = ((rbit_s+wbit_s)*100/max_bit);
|
||||
|
||||
|
Reference in New Issue
Block a user