Skip to content

Commit

Permalink
core-smart.h: more SMART helper definitions to core-smart.h from stre…
Browse files Browse the repository at this point in the history
…ss-ng.h

Signed-off-by: Colin Ian King <[email protected]>
  • Loading branch information
ColinIanKing committed Jan 24, 2022
1 parent e679163 commit 155301b
Show file tree
Hide file tree
Showing 4 changed files with 31 additions and 7 deletions.
5 changes: 3 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -407,7 +407,8 @@ OBJS += $(CONFIG_OBJS)
.o: Makefile

%.o: %.c stress-ng.h config.h git-commit-id.h core-capabilities.h core-put.h \
core-target-clones.h core-pragma.h core-perf.h core-thermal-zone.h
core-target-clones.h core-pragma.h core-perf.h core-thermal-zone.h \
core-smart.h
$(Q)echo "CC $<"
$(V)$(CC) $(CFLAGS) -c -o $@ $<

Expand Down Expand Up @@ -493,7 +494,7 @@ dist:
mkdir stress-ng-$(VERSION)
cp -rp Makefile Makefile.config $(SRC) stress-ng.h stress-ng.1 \
core-capabilities.h core-put.h core-target-clones.h \
core-pragma.h core-perf.h core-thermal-zone.h \
core-pragma.h core-perf.h core-thermal-zone.h core-smart.h \
core-personality.c core-io-uring.c \
COPYING syscalls.txt mascot README.md \
stress-af-alg-defconfigs.h README.Android test snap \
Expand Down
26 changes: 26 additions & 0 deletions core-smart.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
/*
* Copyright (C) 2022 Colin Ian King
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*
*/
#ifndef CORE_SMART_H
#define CORE_SMART_H

/* S.M.A.R.T. helpers */
extern void stress_smart_start(void);
extern void stress_smart_stop(void);

#endif
3 changes: 2 additions & 1 deletion stress-ng.c
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,9 @@
*
*/
#include "stress-ng.h"
#include "core-perf.h"
#include "core-hash.h"
#include "core-perf.h"
#include "core-smart.h"
#include "core-thermal-zone.h"

typedef struct {
Expand Down
4 changes: 0 additions & 4 deletions stress-ng.h
Original file line number Diff line number Diff line change
Expand Up @@ -3649,10 +3649,6 @@ extern WARN_UNUSED bool stress_redo_fork(const int err);
extern void stress_sighandler_nop(int sig);
extern int stress_killpid(const pid_t pid);

/* S.M.A.R.T. helpers */
extern void stress_smart_start(void);
extern void stress_smart_stop(void);

/* ftrace helpers */
extern int stress_ftrace_start(void);
extern void stress_ftrace_stop(void);
Expand Down

0 comments on commit 155301b

Please sign in to comment.