diff --git a/salt/loader.py b/salt/loader.py
index <HASH>..<HASH> 100644
--- a/salt/loader.py
+++ b/salt/loader.py
@@ -231,10 +231,12 @@ def log_handlers(opts):
     return load.filter_func('setup_handlers')
 
 
-def ssh_wrapper(opts):
+def ssh_wrapper(opts, functions=None):
     '''
     Returns the custom logging handler modules
     '''
+    if functions is None:
+        functions = {}
     load = _create_loader(
         opts,
         'wrapper',
@@ -245,7 +247,9 @@ def ssh_wrapper(opts):
             'ssh',
             'wrapper'))
     )
-    return load.gen_functions()
+    pack = {'name': '__salt__',
+            'value': functions}
+    return load.gen_functions(pack)
 
 
 def render(opts, functions):
update ssh loader routines to take the wrapper as __salt__