|
|
@@ -19,6 +19,7 @@
|
|
|
#include "fpgautils.h"
|
|
|
#include "libbitfury.h"
|
|
|
#include "logging.h"
|
|
|
+#include "lowlevel.h"
|
|
|
#include "miner.h"
|
|
|
#include "spidevc.h"
|
|
|
#include "util.h"
|
|
|
@@ -222,6 +223,12 @@ bool littlefury_txrx(struct spi_port *port)
|
|
|
return true;
|
|
|
}
|
|
|
|
|
|
+static
|
|
|
+bool littlefury_lowl_match(const struct lowlevel_device_info * const info)
|
|
|
+{
|
|
|
+ return lowlevel_match_lowlproduct(info, &lowl_vcom, "LittleFury");
|
|
|
+}
|
|
|
+
|
|
|
static
|
|
|
bool littlefury_detect_one(const char *devpath)
|
|
|
{
|
|
|
@@ -310,15 +317,9 @@ err:
|
|
|
}
|
|
|
|
|
|
static
|
|
|
-int littlefury_detect_auto(void)
|
|
|
-{
|
|
|
- return serial_autodetect(littlefury_detect_one, "LittleFury");
|
|
|
-}
|
|
|
-
|
|
|
-static
|
|
|
-void littlefury_detect(void)
|
|
|
+bool littlefury_lowl_probe(const struct lowlevel_device_info * const info)
|
|
|
{
|
|
|
- serial_detect_auto(&littlefury_drv, littlefury_detect_one, littlefury_detect_auto);
|
|
|
+ return vcom_lowl_probe_wrapper(info, littlefury_detect_one);
|
|
|
}
|
|
|
|
|
|
static
|
|
|
@@ -470,7 +471,8 @@ void littlefury_reinit(struct cgpu_info * const proc)
|
|
|
struct device_drv littlefury_drv = {
|
|
|
.dname = "littlefury",
|
|
|
.name = "LFY",
|
|
|
- .drv_detect = littlefury_detect,
|
|
|
+ .lowl_match = littlefury_lowl_match,
|
|
|
+ .lowl_probe = littlefury_lowl_probe,
|
|
|
|
|
|
.thread_init = littlefury_thread_init,
|
|
|
.thread_disable = littlefury_disable,
|