Commit 46168810 authored by Erik Arfvidson's avatar Erik Arfvidson Committed by Greg Kroah-Hartman

staging: unisys: move parser.[ch] functionality into visorchipset

This patch moves includes files and functions from parser.[ch] into
visorchipset.
Signed-off-by: default avatarErik Arfvidson <erik.arfvidson@unisys.com>
Signed-off-by: default avatarBenjamin Romer <benjamin.romer@unisys.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent e3420ed6
......@@ -2040,7 +2040,7 @@ visorbus_init(void)
POSTCODE_LINUX_3(DRIVER_ENTRY_PC, rc, POSTCODE_SEVERITY_INFO);
bus_device_info_init(&clientbus_driverinfo,
"clientbus", MYDRVNAME,
"clientbus", "visorbus",
VERSION, NULL);
/* process module options */
......
......@@ -4,7 +4,7 @@
obj-$(CONFIG_UNISYS_VISORCHIPSET) += visorchipset.o
visorchipset-y := visorchipset_main.o parser.o
visorchipset-y := visorchipset_main.o
ccflags-y += -Idrivers/staging/unisys/include
ccflags-y += -Idrivers/staging/unisys/uislib
......
This diff is collapsed.
/* parser.h
*
* Copyright (C) 2010 - 2013 UNISYS CORPORATION
* All rights reserved.
*
* 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, GOOD TITLE or
* NON INFRINGEMENT. See the GNU General Public License for more
* details.
*/
#ifndef __PARSER_H__
#define __PARSER_H__
#include <linux/uuid.h>
#include "channel.h"
typedef enum {
PARSERSTRING_INITIATOR,
PARSERSTRING_TARGET,
PARSERSTRING_CONNECTION,
PARSERSTRING_NAME,
} PARSER_WHICH_STRING;
struct parser_context *parser_init(u64 addr, u32 bytes, bool isLocal,
bool *tryAgain);
struct parser_context *parser_init_byte_stream(u64 addr, u32 bytes, bool local,
bool *retry);
void parser_param_start(struct parser_context *ctx,
PARSER_WHICH_STRING which_string);
void *parser_param_get(struct parser_context *ctx, char *nam, int namesize);
void *parser_string_get(struct parser_context *ctx);
uuid_le parser_id_get(struct parser_context *ctx);
char *parser_simpleString_get(struct parser_context *ctx);
void *parser_byte_stream_get(struct parser_context *ctx, unsigned long *nbytes);
void parser_done(struct parser_context *ctx);
#endif
......@@ -22,17 +22,37 @@
#include "channel.h"
#include "controlvmchannel.h"
#include "parser.h"
#include "procobjecttree.h"
#include "vbusdeviceinfo.h"
#include "vbushelper.h"
#define MYDRVNAME "visorchipset"
#define VISORCHIPSET_MMAP_CONTROLCHANOFFSET 0x00000000
/** Describes the state from the perspective of which controlvm messages have
* been received for a bus or device.
*/
enum PARSER_WHICH_STRING {
PARSERSTRING_INITIATOR,
PARSERSTRING_TARGET,
PARSERSTRING_CONNECTION,
PARSERSTRING_NAME,
};
struct visorchannel;
struct parser_context *parser_init(u64 addr, u32 bytes, bool isLocal,
bool *tryAgain);
struct parser_context *parser_init_byte_stream(u64 addr, u32 bytes, bool local,
bool *retry);
void parser_param_start(struct parser_context *ctx,
PARSER_WHICH_STRING which_string);
void *parser_param_get(struct parser_context *ctx, char *nam, int namesize);
void *parser_string_get(struct parser_context *ctx);
uuid_le parser_id_get(struct parser_context *ctx);
char *parser_simpleString_get(struct parser_context *ctx);
void *parser_byte_stream_get(struct parser_context *ctx, unsigned long *nbytes);
void parser_done(struct parser_context *ctx);
struct visorchipset_state {
u32 created:1;
u32 attached:1;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment