#include <bits/stdc++.h>
using namespace std;
const int maxn = 1e5 + 100;
int b[maxn], g[maxn];
int cnt[maxn];
struct P {
  int i;
  int val;
  bool operator<(const P& rhs) const { return val < rhs.val; }
};
multiset<P> s;
multiset<P>::iterator it;
multiset<int> s2;
int n, m;
long long solve(long long res) {
  for (int i = 0; i < m; i++) {
    if (s2.upper_bound(g[i]) != s2.end()) return -1;
    if (s2.find(g[i]) != s2.end()) {
      continue;
    }
    bool flag = 0;
    while (1) {
      it = s.upper_bound(P{0, -g[i]});
      if (it == s.end()) break;
      if (cnt[(*it).i] >= m - 1) {
        s.erase(it);
        continue;
      }
      flag = 1;
      cnt[(*it).i]++;
      res += (*it).val + g[i];
      break;
    }
    if (!flag) {
      return -1;
    }
  }
  return res;
}
int main() {
  std::ios::sync_with_stdio(false);
  cin >> n >> m;
  long long res = 0;
  for (int i = 0; i < n; i++) {
    int x;
    cin >> x;
    s.insert(P{i, -x});
    s2.insert(x);
    res += (long long)x * (long long)m;
  }
  for (int i = 0; i < m; i++) {
    cin >> g[i];
  }
  cout << solve(res) << endl;
  return 0;
}
