troky
1bd9636602
Fixed found blocks calculation.
2014-05-27 11:41:17 +02:00
sterlingpickens
812efe4abc
initial_args warning
...
Remove #ifdef WIN32 "static const char *" appears to be ok for all platforms.
2014-05-26 23:26:27 -07:00
sterlingpickens
246615f238
initial_args warning
...
Provide for WIN32 and non-WIN32 condition for initial_args malloc (compiler warning)
and remove redundant static.
2014-05-26 19:53:27 -07:00
troky
22a3c5b6fe
Reverting 83d71da
. VS2010 fix.
2014-05-22 09:55:43 +02:00
Noel Maersk
ecfd497467
core: remove second-to-last remnants of hotplug.
...
If you grep hotplug, you'll find two more occurences as a function
argument, but it's unused.
2014-05-11 17:28:25 +03:00
elbandi
e32dcd7190
Mark pool as idle if stratum restart is failed
2014-05-08 00:04:01 +02:00
elbandi
98676763b9
Set the pool idle and switch pool, if need
2014-05-08 00:02:39 +02:00
Noel Maersk
5b054542db
config: Don't write commas if not needed, default to opt_algorithm
when adding pool without one set explicitly.
2014-05-05 15:34:02 +03:00
sterlingpickens
83d71da225
Update sgminer.c
2014-05-02 09:36:35 -07:00
Elbandi
973dcefa8c
Use get_pool_name everywhere
2014-04-24 12:09:56 +02:00
Noel Maersk
3d7167ce2c
config: improve pool section writing.
...
Order so JSON's not broken, write `priority` and `algorithm`.
Closes #102 .
2014-04-18 17:31:06 +03:00
Noel Maersk
92c3b5eb48
api: set algorithm properly on addpool.
2014-04-12 17:32:41 +03:00
Noel Maersk
3c3a58475e
ui+api: ask for pool name/description/algorithm when adding pool from NCurses/API.
...
Closes #116 .
This is trivial and shouldn't be so hard: it required modifying
functions in both sgminer.c (for NCurses stuff) and api.c. There is
much code repetition, since the NCurses interface is hard-coded in.
Removing it would simplify things greatly.
2014-04-11 15:06:36 +03:00
troky
01e96606f0
Fixed (pool) algo selection.
2014-04-11 10:41:37 +02:00
Noel Maersk
da667d63e0
config: write pool name and description to config.
2014-04-11 03:01:13 +03:00
Noel Maersk
2c00158216
Merge pull request #189 from Bllacky/patch-7
...
Update sgminer.c
2014-04-10 18:47:28 +03:00
Noel Maersk
b3d483a035
core: revert two of the changes in Bllacky's pull request #187 .
...
`ndigits` is actually an int, used as a field width specifier in
snprintf().
s is an extensively-used pointer.
2014-04-09 22:37:07 +03:00
Bllacky
fe64ac99d6
Update sgminer.c
...
One small change to work well with previous ones.
Number of warnings now is 151, down from 157.
Still a long way to go. Most of the serious warnings are related to variables in miner.h, which is so intertwined with everything else that I fear of breaking something or making performance worse if I touch miner.h too much.
2014-04-09 22:17:37 +03:00
Bllacky
1dc8aabda9
Update sgminer.c
...
Minor changes to variable declaration.
Should reduce the number of warnings by about 5.
2014-04-09 22:03:12 +03:00
Noel Maersk
aa5f4c713b
config: add const
qualifier to set_pool_{algorithm,nfactor}().
...
MSVS doesn't like implicit casting.
2014-04-08 14:28:50 +03:00
Noel Maersk
e7078a5e16
misc: clarify currentpool() comment.
2014-04-07 22:51:23 +03:00
Noel Maersk
f6616aa63b
config: allow specifying per-pool algorithm with --algorithm
instead of --pool-algorithm
.
...
This will probably only work with config file, though, since it relies
on json_array_index.
2014-04-07 22:43:43 +03:00
Noel Maersk
53a199a21d
config: use get_pool_name() in set_pool_algorithm() and set_pool_nfactor().
2014-04-07 22:21:57 +03:00
Noel Maersk
af879b1c77
core/misc: rename set_poolname() to set_pool_name().
2014-04-07 22:19:57 +03:00
Noel Maersk
3ddf6baad9
core: rename default_algorithm to opt_algorithm.
...
... So it's easier to find when refactoring the configuration system
later on.
2014-04-07 22:09:05 +03:00
Noel Maersk
0793c96074
Merge remote-tracking branch 'mrbrdo/poolalgo' into poolalgo
...
Conflicts (resolved):
ocl.h
sgminer.c
2014-04-07 22:05:33 +03:00
Noel Maersk
b6218e20c1
config: rename --pool-priority to --priority, --coin to --description.
...
There are now get_current_pool() and current_pool(), which is confusing.
Moved them closer together, so it's at least obvious.
2014-04-07 21:14:17 +03:00
Jan Berdajs
cdb817bcbd
Change algorithm more robustly and faster, previous way was buggy
2014-03-31 21:05:20 +02:00
Jan Berdajs
c2131df6aa
add support for setting algorithm/nfactor for each pool separately, and fix bugged OpenCL thread cleanup (thread shutdown)
2014-03-31 21:05:20 +02:00
Noel Maersk
a57f841570
Revert "fix for mingw-w64"
...
This reverts commit 32b13ccb46
.
Reported by Wolf0 (aka wolf9466) to not break MinGW 64-bit compilation
with GCC 4.8.2 (latest stable).
2014-03-29 03:04:30 +02:00
Noel Maersk
db0f7cf6f0
core: silence gcc warning about sprintf() use in add_pool() - this time for sure.
2014-03-28 17:21:10 +02:00
Noel Maersk
5896da18b1
core: remove total_users, total_passes, total_userpasses (no longer used).
...
Silence gcc warnings.
Need for these accounting vars removed a few commits ago by troky.
2014-03-28 16:30:11 +02:00
Noel Maersk
08ff1574df
config: write algorithm
to config if not default.
...
Closes https://github.com/veox/sgminer/issues/175
2014-03-28 16:28:15 +02:00
Noel Maersk
8203fea539
config: move --coin
in config table (alphabetically).
2014-03-27 17:58:16 +02:00
Noel Maersk
e7ca7fabba
Merge pull request #168 from troky/testing
...
--pool-priority, --coin and fix for #80
2014-03-27 17:51:01 +02:00
Noel Maersk
10ec7769c8
pool: don't pass unused argument to sprintf() in add_pool().
...
Silences gcc warning.
2014-03-26 18:41:18 +02:00
Noel Maersk
ac3d13880c
Revert "core: correctly parse boolean configuration values."
...
This reverts commit 8dd1c2d4af
.
Introduced a security bug: since CCAN/opt is used to parse the JSON
config (something it is not meant to do), it was possible to specify
the default of
"api-listen":false
in .conf and expect the API to be disabled. However, since CCAN/opt
does not check for parameters to OPT_WITHOUT_ARG, this got set to
true anyway, and enabled the API on a (possibly unfirewalled) network.
For this reason, configuration options are not named uniformly.
This should have been reverted as soon as it became known:
4c4b909be6
(Fri Feb 28)
Sorry for that.
2014-03-26 18:34:49 +02:00
troky
bcb78ed91b
Added --coin pool parameter.
2014-03-26 11:10:41 +01:00
troky
17f5e296a9
Fixed configuration/command line parsing.
2014-03-26 10:46:17 +01:00
troky
8db53026cb
Added --pool-priority
2014-03-25 20:37:45 +01:00
Martin Danielsen
01b3f70b63
A new --no-client-reconnect command that disables the 'client.reconnect' function.
...
It looks like there's an exploit that abuses said command, but it is still not clear exactly how.
There's also an additional message when the reconnect happens: "WARNING: POTENTIAL CLIENT.EXPLOIT!", but it requires you to be actively monitoring your log to catch it, and in which case you already get a "Reconnect requested from Pool 0 to 127.0.0.1" message.
Note that disabling 'client.reconnect' might affect some pools that rely on the feature, like pools that you lease your rig to.
Oh and this is dry-coded. :)
2014-03-24 15:12:40 +02:00
Noel Maersk
106dbee1f9
core: check if GPU thread is disabled before checking if it's waiting on getwork.
...
Otherwise the watchdog thread segfaults on checking an uninitialised
thr->getwork value.
2014-03-17 21:57:00 +02:00
Noel Maersk
87801c2578
opencl: rename cgpu_info->kname to cgpu_info->kernelname.
2014-03-17 21:57:00 +02:00
Noel Maersk
1333ed576d
core: simplify kernel selection code.
...
WIP!
Use a string instead of a state-machine-ey kernel selection mechanism
where kernel names have to be predefined. This should allow just dropping
new kernels into dir `kernel` without bloating the code in three other
places.
Is in dire need of a cleanup, function parameter check, edge case check -
all the usual testing.
In particular, checking these definitions/keywords:
* enum cl_kernels
* kname
* [c]gpu[s]->kernel (and similar)
* memory cleanup after strdup()?..
* chosen_kernel
* queue_scrypt_kernel
* strbuf
* initCl
2014-03-17 21:56:43 +02:00
Noel Maersk
fc902f0f41
pool: add back --poolname as hidden option for backward compatibility.
...
+ Udate NEWS.
2014-03-15 19:08:24 +02:00
troky
49aef7100f
Reverting "poolname" to "name".
2014-03-15 19:08:24 +02:00
unknown
958764fecc
MSVS build: Fixed debug build. MSVS doesn't like uninitialized variables.
2014-03-15 12:47:32 +01:00
Noel Maersk
8079d054d6
Merge branch 'nfactor'
...
Conflicts (resolved):
Makefile.am
winbuild/sgminer.vcxproj.filters
2014-03-14 17:46:54 +02:00
unknown
0e37fc24b0
Added algorrithm name to "coin" API command. Changed default algo name to "scrypt".
2014-03-13 23:02:51 +01:00
Noel Maersk
a3f9b24c69
core: set default algorithm for when neither --algorithm nor --nfactor are provided.
2014-03-07 02:27:06 +02:00